Skip to content

Commit 463eb92

Browse files
committed
Update an example test
1 parent 2f56b9c commit 463eb92

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

examples/raw_browser_launcher.py

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,12 @@
99
success = False
1010
try:
1111
driver = get_driver("chrome", headless=False)
12-
driver.get('data:text/html,<h1 class="top">Data URL</h2>')
13-
source = driver.page_source
14-
assert "Data URL" in source
15-
# An example of "is_element_visible()" from "page_actions"
16-
assert page_actions.is_element_visible(driver, "h1.top")
17-
# Extra fun with Javascript
18-
js_utils.highlight_with_js(driver, "h1.top", 8, "")
19-
success = True # No errors
12+
driver.get("https://seleniumbase.io/apps/calculator")
13+
page_actions.wait_for_element_visible(driver, "4", "id").click()
14+
page_actions.wait_for_element_visible(driver, "2", "id").click()
15+
page_actions.wait_for_text_visible(driver, "42", "output", "id")
16+
js_utils.highlight_with_js(driver, "#output", 6, "")
17+
success = True
2018
finally:
2119
driver.quit()
2220
assert success

0 commit comments

Comments
 (0)