From 6fc32e102899ed1a0780e91afbc1c7728b7578e7 Mon Sep 17 00:00:00 2001 From: Hui Lan Date: Wed, 10 Feb 2021 23:03:28 +0800 Subject: app/main.py and app/test/test_add_word.py: use class instead of id. --- app/test/test_add_word.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/test/test_add_word.py') diff --git a/app/test/test_add_word.py b/app/test/test_add_word.py index 4fb38bc..01d867f 100644 --- a/app/test/test_add_word.py +++ b/app/test/test_add_word.py @@ -61,7 +61,7 @@ def test_add_word(): elem = driver.find_element_by_xpath('//form[1]/input[1]') # 找到加入我的生词簿按钮 elem.click() - elems = driver.find_elements_by_xpath("//p[@id='new-word']") + elems = driver.find_elements_by_xpath("//p[@class='new-word']") elems[0].location_once_scrolled_into_view driver.save_screenshot('./app/test/test_add_word_pic3.png') -- cgit v1.2.1