From 55b2c6c63e3e73b408002f4c17713c843be1297d Mon Sep 17 00:00:00 2001 From: Constantin Hong Date: Wed, 8 May 2024 01:36:04 +0900 Subject: [PATCH] tests/test_xpath_selector_unit/test: Oops fix test name --- changedetectionio/tests/test_xpath_selector_unit.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/changedetectionio/tests/test_xpath_selector_unit.py b/changedetectionio/tests/test_xpath_selector_unit.py index ebbaf23a..95bdb525 100644 --- a/changedetectionio/tests/test_xpath_selector_unit.py +++ b/changedetectionio/tests/test_xpath_selector_unit.py @@ -229,7 +229,7 @@ DOM_violation_two_html_root_element = """ ("//html[2]/body/p[1]", "First paragraph."), ("//html[2]/body/p[1]", "Browsers parse this part by fixing it but lxml doesn't and returns two root element node"), ]) -def test_trips(html_content, xpath, answer): +def test_broken_DOM_01(html_content, xpath, answer): # In normal situation, DOM's root element node is only one. So when DOM violation happens, Exception occurs. with pytest.raises(Exception): from lxml import etree, html @@ -250,7 +250,7 @@ def test_trips(html_content, xpath, answer): ("/html[2]/body/p[1]", "First paragraph."), ("//html[2]/body/p[1]", "First paragraph."), ]) -def test_trips(html_content, xpath, answer): +def test_Broken_DOM_02(html_content, xpath, answer): # In normal situation, DOM's root element node is only one. So when DOM violation happens, Exception occurs. html_content = html_tools.xpath_filter(xpath, html_content, append_pretty_line_formatting=True) assert type(html_content) == str