From 093e76fa15f7475cd3f0e6be9cfe60ca2da608c4 Mon Sep 17 00:00:00 2001 From: Julie Date: Fri, 23 May 2014 10:41:32 -0700 Subject: [PATCH] tests(docsAppE2E): fix race condition flake with switching to new frame Closes #7569 --- test/e2e/docsAppE2E.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/e2e/docsAppE2E.js b/test/e2e/docsAppE2E.js index 8fe30c38..371b784d 100644 --- a/test/e2e/docsAppE2E.js +++ b/test/e2e/docsAppE2E.js @@ -27,8 +27,8 @@ describe('docs.angularjs.org', function () { it('should show the functioning input directive example', function () { browser.get('index-debug.html#!/api/ng/directive/input'); - //Wait for animation - browser.sleep(500); + // Ensure that the page is loaded before trying to switch frames. + browser.waitForAngular(); browser.switchTo().frame('example-input-directive'); @@ -66,4 +66,4 @@ describe('docs.angularjs.org', function () { expect(element(by.css('.minerr-errmsg')).getText()).toEqual("Argument 'Missing' is not a function, got undefined"); }); }); -}); \ No newline at end of file +});