-
-
Couldn't load subscription status.
- Fork 49
Closed
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Thanks for the great plugin!
I noticed the following:
Example 1:
import requests
def test():
requests.get("http://httpbin.org/status/200")This will raise SocketBlockedError, as expected.
Example 2:
import pytest
import requests
@pytest.fixture # scope == "function" by default
def getit():
requests.get("http://httpbin.org/status/200")
def test(getit):
passThis will also raise the SocketBlockedError. Also as expected.
Example 3:
import pytest
import requests
@pytest.fixture(scope="module") # <== Notice the different scope!
def getit():
requests.get("http://httpbin.org/status/200")
def test(getit):
passThis will pass. No exception.
To me, this was unexpected and lead to some debugging headaches.
Is this intended behavior or a bug? Is there a way to make the plugin also prevent cases such as this one?
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation