refactor(api)!: Unifying log under 1 logger and removing debug parameter
So now you control the logging and the debugging from the shell through the logger with the name 'scrapling'
This commit is contained in:
@@ -42,8 +42,8 @@ class TestParserAutoMatch(unittest.TestCase):
|
||||
</div>
|
||||
'''
|
||||
|
||||
old_page = Adaptor(original_html, url='example.com', auto_match=True, debug=True)
|
||||
new_page = Adaptor(changed_html, url='example.com', auto_match=True, debug=True)
|
||||
old_page = Adaptor(original_html, url='example.com', auto_match=True)
|
||||
new_page = Adaptor(changed_html, url='example.com', auto_match=True)
|
||||
|
||||
# 'p1' was used as ID and now it's not and all the path elements have changes
|
||||
# Also at the same time testing auto-match vs combined selectors
|
||||
|
||||
@@ -74,7 +74,7 @@ class TestParser(unittest.TestCase):
|
||||
</body>
|
||||
</html>
|
||||
'''
|
||||
self.page = Adaptor(self.html, auto_match=False, debug=False)
|
||||
self.page = Adaptor(self.html, auto_match=False)
|
||||
|
||||
def test_css_selector(self):
|
||||
"""Test Selecting elements with complex CSS selectors"""
|
||||
@@ -273,7 +273,7 @@ class TestParser(unittest.TestCase):
|
||||
large_html = '<html><body>' + '<div class="item">' * 5000 + '</div>' * 5000 + '</body></html>'
|
||||
|
||||
start_time = time.time()
|
||||
parsed = Adaptor(large_html, auto_match=False, debug=False)
|
||||
parsed = Adaptor(large_html, auto_match=False)
|
||||
elements = parsed.css('.item')
|
||||
end_time = time.time()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user