You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fork and clone the repository to local. I ran the test with python3 -m test_howdoi. I get the following result.
Traceback (most recent call last):
File "/Users/XXX/Projects/howdoi/test_howdoi.py", line 270, in test_missing_pre_or_code_query
self.assertIn('XML elements present in a XML', output)
AssertionError: 'XML elements present in a XML' not found in '<people>\n <student>\n <name>John</name>\n </student>\n</people>\n'
What you expected to happen:
If the page_cache was working, the test should pass.
However, for some reason, it is not using page_cache and fetching the latest answer from stackoverflow, which has different order compared to cached_html, resulting in test failure.
The text was updated successfully, but these errors were encountered:
Run python -m nose test_howdoi:HowdoiTestCase.test_missing_pre_or_code_query and you'll see that the first time _get_result is called for the Google search it will use the page_cache, but the second time when we call it for the Stack Overflow answer the mocked function is not used.
My guess is that something about how we mock the function is not correct.
Resolved the duckduckgo not found issue in the test_howdoi.py file by updating the old pacakges of duckduckgo to duckduckpy and now the duckduckgo issue in the testing file is gone, still having issue with the XML file like some parameters are being missing...
What happened:
Fork and clone the repository to local. I ran the test with
python3 -m test_howdoi
. I get the following result.What you expected to happen:
If the page_cache was working, the test should pass.
However, for some reason, it is not using page_cache and fetching the latest answer from stackoverflow, which has different order compared to cached_html, resulting in test failure.
The text was updated successfully, but these errors were encountered: