Пример #1
0
Файл: Xpath.py Проект: aaape/WM
from selenium_learn import webdriver

dr = webdriver.Firefox()

# 绝对路径
dr.find_element_by_xpath("/html/body/div/div/")

# 相对路劲
dr.find_element_by_xpath("//input[]")
Пример #2
0
 def setUp(self):
     self.driver = webdriver.Firefox()
     self.driver.implicitly_wait(30)
     self.driver.maximize_window()
     self.driver.get("file://C:\\Users\\55077\\Desktop\\test.html")
Пример #3
0
 def setUp(self):
     self.driver = webdriver.Firefox()
     self.driver.get("")
Пример #4
0
 def setUp(self):
     self.driver = webdriver.Firefox()
     self.driver.implicitly_wait(30)
     self.driver.maximize_window()
     self.driver.get("http://www.baidu.com")
Пример #5
0
 def setUp(self):
     self.driver = webdriver.Firefox()
     self.driver.implicitly_wait(30)
     self.driver.maximize_window()
     # navigate to the application home page
     self.driver.get("http://demo.magentocommerce.com")
Пример #6
0
Файл: fun.py Проект: aaape/WM
 def setUp(self):
     self.driver = webdriver.Firefox()
     self.driver.get("http://demo.magentocommerce.com/")