MCPcopy Create free account
hub / github.com/seleniumbase/SeleniumBase / MyTestClass

Class MyTestClass

examples/my_first_test.py:6–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4
5
6class MyTestClass(BaseCase):
7 def test_swag_labs(self):
8 self.goto("https://www.saucedemo.com")
9 self.type("#user-name", "standard_user")
10 self.type("#password", "secret_sauce\n")
11 self.assert_element("div.inventory_list")
12 self.assert_exact_text("Products", "span.title")
13 self.click('button[name*="backpack"]')
14 self.click("#shopping_cart_container a")
15 self.assert_exact_text("Your Cart", "span.title")
16 self.assert_text("Backpack", "div.cart_item")
17 self.click("button#checkout")
18 self.type("#first-name", "SeleniumBase")
19 self.type("#last-name", "Automation")
20 self.type("#postal-code", "77123")
21 self.click("input#continue")
22 self.assert_text("Checkout: Overview")
23 self.assert_text("Backpack", "div.cart_item")
24 self.assert_text("29.99", "div.inventory_item_price")
25 self.click("button#finish")
26 self.assert_exact_text("Thank you for your order!", "h2")
27 self.assert_element('img[alt="Pony Express"]')
28 self.js_click("a#logout_sidebar_link")
29 self.assert_element("div#login_button_container")
30
31
32#######################################################################

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…