-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathconf.ts
49 lines (40 loc) · 1.7 KB
/
conf.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import { browser } from "protractor";
// Require protractor-beautiful-reporter to generate reports.
var HtmlReporter = require('protractor-beautiful-reporter');
exports.config = {
directConnect: true,
// Capabilities to be passed to the webdriver instance.
capabilities: {
'browserName': 'chrome',
chromeOptions: {
args: ['--disable-gpu']
}
},
// If you have one app to test then you can mention the base url here.
// baseUrl: 'https://juliemr.github.io/protractor-demo/',
// Framework to use. Jasmine is recommended.
framework: 'jasmine2',
specs: ['../temp/test-suites/*.js'],
// Options to be passed to Jasmine.
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 90000,
isVerbose: true
},
onPrepare: () => {
browser.manage().window().maximize();
browser.manage().timeouts().implicitlyWait(5000);
// Add a screenshot reporter and store screenshots to `./test-results`:
jasmine.getEnv().addReporter(new HtmlReporter({
baseDirectory: 'test-results',
preserveDirectory: false, // Preserve base directory
screenshotsSubfolder: 'screenshots',
jsonsSubfolder: 'jsons', // JSONs Subfolder
takeScreenShotsForSkippedSpecs: true, // Screenshots for skipped test cases
takeScreenShotsOnlyForFailedSpecs: false, // Screenshots only for failed test cases
docTitle: 'Test Automation Execution Report', // Add title for the html report
docName: 'TestResult.html', // Change html report file name
gatherBrowserLogs: true // Store Browser logs
}).getJasmine2Reporter());
}
}