上传文件至 app/test
parent
eaf57fc54d
commit
2a60eec12c
|
@ -17,11 +17,13 @@ def test_highlight(driver, URL):
|
|||
article = driver.find_element_by_id("article")
|
||||
actions = ActionChains(driver)
|
||||
actions.move_to_element(article).click_and_hold().move_by_offset(450,60).release().perform()
|
||||
time.sleep(1)
|
||||
|
||||
# 判断所有高亮单词是否有间隔
|
||||
marks = driver.find_elements_by_tag_name("mark")
|
||||
for mark in marks:
|
||||
assert mark.value_of_css_property("padding") == '0px'
|
||||
time.sleep(5)
|
||||
finally:
|
||||
# 测试结束后关闭浏览器
|
||||
driver.quit()
|
||||
|
|
Loading…
Reference in New Issue