import pytest from selenium import webdriver from selenium.webdriver.common.by import By from selenium.webdriver.support.ui import WebDriverWait from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver import Firefox from selenium.webdriver.common.keys import Keys class Tags: starSysButton = '//li[button][1]' solPath = f"//td[contains(text(),'Sol')]" @pytest.fixture def browser(): driver = Firefox() driver.implicitly_wait(10) yield driver driver.quit() def test_basic_landing_page(browser): URL = 'http://localhost:4200' browser.get(URL) starElement = browser.find_element(By.XPATH(Tags.starSysButton)) starElement.click() results = browser.find_element(By.XPATH(Tags.solPath)) if results: assert results
starElement = browser.find_element(By.XPATH, Tags.starSysButton)
results = browser.find_element(By.XPATH, Tags.solPath)
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)