devops:selenium
This is an old revision of the document!
Table of Contents
Selenium
To record the cases use chrome plugin: “Katalon Recorder (Selenium IDE for Chrome)”
Download the chromedriver: http://chromedriver.storage.googleapis.com/index.html And use it within the script
Here is a demo script: <sxh python> from selenium import webdriver chromedriver = “..ChromeWebDriverchromedriver.exe” driver = webdriver.Chrome(chromedriver) driver.get(“http://localhost:8080”) assert “Frontend” in driver.title
elem = driver.set_window_size(1800,800)
driver.find_element_by_id(“menu-about”).click();
elem = driver.save_screenshot('screen1.png')
driver.quit() </python>
devops/selenium.1520937299.txt.gz · Last modified: (external edit)