print"Claim"
time.sleep(5)
browser.find_element_by_xpath("//ul[@id='menu']/li[3]/a").click()
print"new claim"
time.sleep(3)
browser.find_element_by_xpath("//button[@id='btnNew']").click()
assert"Claim"in browser.title
browser.find_element_by_xpath("//ul[@id='menu']/li[4]/a").click()
print"contract exception"
time.sleep(3)
browser.find_element_by_id("btnException").click()
print"contract request"
browser.find_element_by_xpath("//ul[@id='menu']/li[5]/a").click()
print"contract request -affiliate link"
time.sleep(3)
问题:有什么方法可以运行的时候提高下速度吗?不要老是加time.sleep(10)
http://docs.seleniumhq.org/docs/04_webdriver_advanced.jsp
用WebDriverWait