From d83ef1a6974d833bae9cee5b3fe7e65f05c3577d Mon Sep 17 00:00:00 2001 From: qiyuan Date: Wed, 28 Feb 2018 12:15:06 +0800 Subject: [PATCH 1/2] add test for fix45 --- tests/test_requests_html.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/tests/test_requests_html.py b/tests/test_requests_html.py index 123444e..d70f03d 100644 --- a/tests/test_requests_html.py +++ b/tests/test_requests_html.py @@ -69,6 +69,13 @@ def test_html_loading(): assert isinstance(html.html, str) +def test_links(): + assert not("#test".startswith('#') and True) is True + assert not("test".startswith('#') and True) is True + + assert not("#test".startswith('#') and False) is True + assert not("test".startswith('#') and False) is True + + if __name__ == '__main__': test_html_loading() - From b78e0e9e730f0403fb18d5a987965e1c489ead11 Mon Sep 17 00:00:00 2001 From: qiyuan Date: Wed, 28 Feb 2018 12:25:18 +0800 Subject: [PATCH 2/2] add test for fix45 --- tests/test_requests_html.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/test_requests_html.py b/tests/test_requests_html.py index d70f03d..1607336 100644 --- a/tests/test_requests_html.py +++ b/tests/test_requests_html.py @@ -70,9 +70,8 @@ def test_html_loading(): def test_links(): - assert not("#test".startswith('#') and True) is True + assert not("#test".startswith('#') and True) is False assert not("test".startswith('#') and True) is True - assert not("#test".startswith('#') and False) is True assert not("test".startswith('#') and False) is True