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 +});