Skip to content

Commit 6ff4cc4

Browse files
committed
fix null test
1 parent 8e72a32 commit 6ff4cc4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

py/test/selenium/webdriver/common/bidi_script_tests.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -593,20 +593,20 @@ def test_unpin_script(driver, pages):
593593
assert result["value"] == "undefined"
594594

595595

596-
def test_execute_script_with_undefined_argument(driver, pages):
596+
def test_execute_script_with_null_argument(driver, pages):
597597
"""Test executing script with undefined argument."""
598598
pages.load("blank.html")
599599

600600
result = driver.script.execute(
601601
"""(arg) => {
602-
if(arg!==undefined)
603-
throw Error("Argument should be undefined, but was "+arg);
602+
if(arg!==null)
603+
throw Error("Argument should be null, but was "+arg);
604604
return arg;
605605
}""",
606606
None,
607607
)
608608

609-
assert result["type"] == "undefined"
609+
assert result["type"] == "null"
610610

611611

612612
def test_execute_script_with_number_argument(driver, pages):

0 commit comments

Comments
 (0)