Skip to content

Commit d1a5201

Browse files
committed
Revert "Fix 3.7 tests"
This reverts commit 99110e9.
1 parent 99110e9 commit d1a5201

3 files changed

Lines changed: 5 additions & 27 deletions

File tree

auth0/test_async/test_async_auth0.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,7 @@ def callback(url, **kwargs):
2222
return callback, mock
2323

2424

25-
@unittest.skipIf(
26-
not hasattr(unittest, "IsolatedAsyncioTestCase"),
27-
"python 3.7 doesn't have IsolatedAsyncioTestCase",
28-
)
29-
class TestAuth0(getattr(unittest, "IsolatedAsyncioTestCase", object)):
25+
class TestAuth0(unittest.IsolatedAsyncioTestCase):
3026
@pytest.mark.asyncio
3127
@aioresponses()
3228
async def test_get(self, mocked):

auth0/test_async/test_async_token_verifier.py

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -55,13 +55,7 @@ def get_pem_bytes(rsa_public_key):
5555
)
5656

5757

58-
@unittest.skipIf(
59-
not hasattr(unittest, "IsolatedAsyncioTestCase"),
60-
"python 3.7 doesn't have IsolatedAsyncioTestCase",
61-
)
62-
class TestAsyncAsymmetricSignatureVerifier(
63-
getattr(unittest, "IsolatedAsyncioTestCase", object)
64-
):
58+
class TestAsyncAsymmetricSignatureVerifier(unittest.IsolatedAsyncioTestCase):
6559
@pytest.mark.asyncio
6660
@aioresponses()
6761
async def test_async_asymmetric_verifier_fetches_key(self, mocked):
@@ -75,11 +69,7 @@ async def test_async_asymmetric_verifier_fetches_key(self, mocked):
7569
self.assertEqual(get_pem_bytes(key), RSA_PUB_KEY_1_PEM)
7670

7771

78-
@unittest.skipIf(
79-
not hasattr(unittest, "IsolatedAsyncioTestCase"),
80-
"python 3.7 doesn't have IsolatedAsyncioTestCase",
81-
)
82-
class TestAsyncJwksFetcher(getattr(unittest, "IsolatedAsyncioTestCase", object)):
72+
class TestAsyncJwksFetcher(unittest.IsolatedAsyncioTestCase):
8373
@pytest.mark.asyncio
8474
@aioresponses()
8575
@unittest.mock.patch(
@@ -235,11 +225,7 @@ async def test_async_fails_to_fetch_jwks_json_after_retrying_twice(self, mocked)
235225
self.assertEqual(mock.call_count, 2)
236226

237227

238-
@unittest.skipIf(
239-
not hasattr(unittest, "IsolatedAsyncioTestCase"),
240-
"python 3.7 doesn't have IsolatedAsyncioTestCase",
241-
)
242-
class TestAsyncTokenVerifier(getattr(unittest, "IsolatedAsyncioTestCase", object)):
228+
class TestAsyncTokenVerifier(unittest.IsolatedAsyncioTestCase):
243229
@pytest.mark.asyncio
244230
@aioresponses()
245231
async def test_RS256_token_signature_passes(self, mocked):

auth0/test_async/test_asyncify.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,7 @@ def callback(url, **kwargs):
5454
return callback, mock
5555

5656

57-
@unittest.skipIf(
58-
not hasattr(unittest, "IsolatedAsyncioTestCase"),
59-
"python 3.7 doesn't have IsolatedAsyncioTestCase",
60-
)
61-
class TestAsyncify(getattr(unittest, "IsolatedAsyncioTestCase", object)):
57+
class TestAsyncify(unittest.IsolatedAsyncioTestCase):
6258
@pytest.mark.asyncio
6359
@aioresponses()
6460
async def test_get(self, mocked):

0 commit comments

Comments
 (0)