diff --git a/tests/frontend/specs/keystroke_urls_become_clickable.js b/tests/frontend/specs/keystroke_urls_become_clickable.js index 3f16ba4e2..64ef3d6a8 100644 --- a/tests/frontend/specs/keystroke_urls_become_clickable.js +++ b/tests/frontend/specs/keystroke_urls_become_clickable.js @@ -16,7 +16,9 @@ describe("urls", function(){ firstTextElement.sendkeys('{selectall}'); // select all firstTextElement.sendkeys('{del}'); // clear the first line firstTextElement.sendkeys('http://etherpad.org'); // insert a URL - - done(); + + helper.waitFor(function(){ + return inner$("div").first().find("a").length === 1; + }, 2000).done(done); }); });