2019-04-25 11:06:40 -04:00
|
|
|
// @ts-check
|
2017-01-27 03:20:51 -05:00
|
|
|
// Protractor configuration file, see link for more information
|
|
|
|
// https://github.com/angular/protractor/blob/master/lib/config.ts
|
|
|
|
|
2020-05-05 08:28:48 -04:00
|
|
|
const { SpecReporter, StacktraceOption } = require('jasmine-spec-reporter');
|
2017-01-27 03:20:51 -05:00
|
|
|
|
2019-04-25 11:06:40 -04:00
|
|
|
/**
|
|
|
|
* @type { import("protractor").Config }
|
|
|
|
*/
|
2017-01-27 03:20:51 -05:00
|
|
|
exports.config = {
|
|
|
|
allScriptsTimeout: 11000,
|
|
|
|
specs: [
|
2019-04-25 11:06:40 -04:00
|
|
|
'./src/**/*.e2e-spec.ts'
|
2017-01-27 03:20:51 -05:00
|
|
|
],
|
|
|
|
capabilities: {
|
2017-02-03 10:44:34 -05:00
|
|
|
browserName: 'chrome',
|
2020-02-13 09:46:38 -05:00
|
|
|
chromeOptions: {
|
2020-02-07 06:38:58 -05:00
|
|
|
binary: require('puppeteer').executablePath(),
|
|
|
|
// See /integration/README.md#browser-tests for more info on these args
|
2020-02-13 09:46:38 -05:00
|
|
|
args: ['--no-sandbox', '--headless', '--disable-gpu', '--disable-dev-shm-usage', '--hide-scrollbars', '--mute-audio'],
|
|
|
|
},
|
2017-01-27 03:20:51 -05:00
|
|
|
},
|
|
|
|
directConnect: true,
|
2020-11-30 16:46:14 -05:00
|
|
|
// Keep the Selenium Promise Manager enabled to avoid flakiness on CI.
|
|
|
|
// See https://github.com/angular/angular/issues/39872 for more details.
|
|
|
|
//
|
|
|
|
// TODO(gkalpak): Set this back to `false` to align with CLI-generated apps when the flakiness is
|
|
|
|
// fixed in the future.
|
|
|
|
SELENIUM_PROMISE_MANAGER: true,
|
2017-01-27 03:20:51 -05:00
|
|
|
baseUrl: 'http://localhost:4200/',
|
2017-02-03 10:44:34 -05:00
|
|
|
framework: 'jasmine',
|
2017-01-27 03:20:51 -05:00
|
|
|
jasmineNodeOpts: {
|
|
|
|
showColors: true,
|
|
|
|
defaultTimeoutInterval: 30000,
|
|
|
|
print: function() {}
|
|
|
|
},
|
2019-04-25 11:06:40 -04:00
|
|
|
onPrepare() {
|
2017-01-27 03:20:51 -05:00
|
|
|
require('ts-node').register({
|
2019-04-25 11:06:40 -04:00
|
|
|
project: require('path').join(__dirname, './tsconfig.json')
|
2017-01-27 03:20:51 -05:00
|
|
|
});
|
2020-05-05 08:28:48 -04:00
|
|
|
jasmine.getEnv().addReporter(new SpecReporter({
|
|
|
|
spec: {
|
|
|
|
displayStacktrace: StacktraceOption.PRETTY,
|
|
|
|
},
|
|
|
|
}));
|
2017-01-27 03:20:51 -05:00
|
|
|
}
|
|
|
|
};
|