sckott / habanero

client for Crossref search API
https://habanero.readthedocs.io
MIT License
207 stars 30 forks source link

Mark two more tests as vcr ones #114

Closed mcepl closed 1 year ago

mcepl commented 1 year ago

We at openSUSE (and the same is true for all other distributions) build our packages in the network isolated environment, so tests of habanero requires switch of all vcr tests and these two should be marked as well:

---
 test/test-content_negotation.py |    2 ++
 1 file changed, 2 insertions(+)

--- a/test/test-content_negotation.py
+++ b/test/test-content_negotation.py
@@ -71,11 +71,13 @@ def test_content_negotiation_raises_an_h

 # warnings
+@pytest.mark.vcr
 def test_content_negotiation_throws_warnings():
     with pytest.warns(UserWarning):
         cn.content_negotiation(ids=["10.1126/science.169.3946.635", "foo"])

+@pytest.mark.vcr
 def test_content_negotiation_throws_warnings_can_be_suppressed():
     warnings.filterwarnings("ignore")
     x = cn.content_negotiation(ids=["10.1126/science.169.3946.635", "foo"])
sckott commented 1 year ago

Thanks! I'll get it done asap

sckott commented 1 year ago

done, i assume you need the new version on pypi for this change to be useful, yes?

mcepl commented 1 year ago

Eventually, I have added this patch to our package now, of course.