Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: test/wrappers/pages.js

Issue 29903561: Noissue - Make test pages automation more reliable against timing issues (Closed)
Patch Set: Created Oct. 6, 2018, 11:43 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/wrappers/pages.js
===================================================================
--- a/test/wrappers/pages.js
+++ b/test/wrappers/pages.js
@@ -188,13 +188,12 @@
});
}
- return takeScreenshot(element).then(screenshot =>
- assert.ok(
+ return this.driver.wait(() =>
+ takeScreenshot(element).then(screenshot =>
screenshot.width == expectedScreenshot.width &&
screenshot.height == expectedScreenshot.height &&
screenshot.data.compare(expectedScreenshot.data) == 0,
- title
- )
+ ), 1000, title
);
});
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld