From 6a13c5b8277cca71a5e30acf8f5f3da7e057d389 Mon Sep 17 00:00:00 2001 From: Waylon Walker Date: Mon, 20 Jul 2020 15:17:53 -0500 Subject: [PATCH] Create sample.py --- sample.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 sample.py diff --git a/sample.py b/sample.py new file mode 100644 index 0000000..c07827e --- /dev/null +++ b/sample.py @@ -0,0 +1,16 @@ +from src.testproject.sdk.drivers import webdriver + +if __name__ == "__main__": + driver = webdriver.Chrome() + + driver.get("https://example.testproject.io/web/") + + driver.find_element_by_css_selector("#name").send_keys("John Smith") + driver.find_element_by_css_selector("#password").send_keys("12345") + driver.find_element_by_css_selector("#login").click() + + passed = driver.find_element_by_css_selector("#logout").is_displayed() + + print("Test passed") if passed else print("Test failed") + + driver.quit()