We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a04ba6e commit 9fa6761Copy full SHA for 9fa6761
1 file changed
tests/integrations/pyramid/test_pyramid.py
@@ -6,6 +6,7 @@
6
import pytest
7
from pyramid.authorization import ACLAuthorizationPolicy
8
from pyramid.response import Response
9
+from packaging.version import Version
10
from werkzeug.test import Client
11
12
from sentry_sdk import capture_message, add_breadcrumb
@@ -18,7 +19,7 @@
18
19
try:
20
from importlib.metadata import version
21
- PYRAMID_VERSION = tuple(map(int, version("pyramid").split(".")))
22
+ PYRAMID_VERSION = Version(version("pyramid"))
23
24
except ImportError:
25
# < py3.8
@@ -311,7 +312,7 @@ def errorhandler(exc, request):
311
312
313
314
@pytest.mark.skipif(
- PYRAMID_VERSION < (1, 9),
315
+ PYRAMID_VERSION < Version("1.9"),
316
reason="We don't have the right hooks in older Pyramid versions",
317
)
318
def test_errorhandler_500(
0 commit comments