Skip to content
This repository was archived by the owner on Jul 29, 2024. It is now read-only.

Commit f034e01

Browse files
committed
fix(synchronizing): use the same control flow when ignoring sync
Previously, the order of frames and tasks on the control flow was different depending on `browser.ignoreSynchronization`. This fixes the inconsistency by creating an empty task when ignoreSynchronization is true. Practically, this fixes the polling spec failing after the update to [email protected].
1 parent 9a202ab commit f034e01

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/protractor.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,9 @@ Protractor.prototype.waitForAngular = function(opt_description) {
320320
var description = opt_description ? ' - ' + opt_description : '';
321321
var self = this;
322322
if (this.ignoreSynchronization) {
323-
return webdriver.promise.fulfilled();
323+
return self.driver.controlFlow().execute(function() {
324+
return true;
325+
}, 'Ignore Synchronization Protractor.waitForAngular()');
324326
}
325327

326328
return this.executeAsyncScript_(

0 commit comments

Comments
 (0)