Skip to content

Commit

Permalink
fix(plugin): global.screenshoterBrowsers
Browse files Browse the repository at this point in the history
breaking change:
global.screenshoterBrowsers is automatically called on beforeAll instead of beforeEach.
  • Loading branch information
azachar committed Nov 28, 2016
1 parent 0556e4c commit 84b09ad
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ protractorUtil.takeScreenshotOnExpectDone = function(context) {
makeAsciiLog = context.config.imageToAscii === 'failure+success' || context.config.imageToAscii === 'failure';
}
} else {
console.warn('Calling addExpectationResult before specStarted!');
console.warn('Calling addExpectationResult before specStarted!');
}
if (makeScreenshotsFromEachBrowsers) {
protractorUtil.takeScreenshot(context, function(filename, browserName, finalFile, browserInstance) {
Expand Down Expand Up @@ -276,15 +276,15 @@ protractorUtil.registerJasmineReporter = function(context) {

jasmine.getEnv().addReporter({
jasmineStarted: function() {
global.screenshotBrowsers = {};

protractorUtil.testResults = [];
protractorUtil.stat = {};
if (context.config.htmlReport) {
protractorUtil.installReporter(context);
}
},
specStarted: function(result) {
global.screenshotBrowsers = {};

protractorUtil.test = {
start: moment(),
specScreenshots: [],
Expand Down

0 comments on commit 84b09ad

Please sign in to comment.