Skip to content

Commit a68b9aa

Browse files
committed
Fix a test broken by closure update in
f91121d This test was trivially passing before because errors were always being caught. The closure update included changes to the testing framework that detected these types of bugs and reported them as failures. I'm not sure what the test was actually trying to exercise, so I've changed it to what I *think* it was going for.
1 parent adee046 commit a68b9aa

1 file changed

Lines changed: 2 additions & 8 deletions

File tree

javascript/webdriver/test/atoms/inject/execute_script_test.html

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,9 @@
5050
assertEquals("there", getValue(webdriver.atoms.inject.executeScript(func, [], win)));
5151
}
5252

53-
function testExecuteScriptWithUnexistingWindow() {
53+
function testExecuteScriptWithNullWindow() {
5454
var func = function () {return document.getElementById('bou').value;};
55-
var win = getValue(webdriver.atoms.inject.frame.findFrameByIdOrName("bou"));
56-
try {
57-
webdriver.atoms.inject.executeScript(func, [], win);
58-
fail();
59-
} catch (e) {
60-
// expected
61-
}
55+
assertEquals("here", getValue(webdriver.atoms.inject.executeScript(func, [], null)));
6256
}
6357

6458
function testExecuteScriptWithoutWindow() {

0 commit comments

Comments
 (0)