Created
February 17, 2023 20:09
-
-
Save maaretp/b9170115d874a8389b09bc73a73b2412 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from selenium import webdriver | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.common.keys import Keys | |
def test_simplest(): | |
driver = webdriver.Chrome() | |
driver.implicitly_wait(10) | |
driver.get("https://todomvc.com/examples/vanillajs/") | |
input_field = driver.find_element(By.CLASS_NAME, "new-todo") | |
input_field.send_keys("Learning Selenium") | |
input_field.send_keys(Keys.ENTER) | |
assert driver.find_element(By.CSS_SELECTOR, ".todo-list li label").text == "Learning Selenium" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment