3030@pytest .mark .parametrize ("application" , APPS )
3131@pytest .mark .asyncio
3232@pytest .mark .forked
33+ @pytest .mark .skipif (
34+ django .VERSION < (3 , 0 ), reason = "Django ASGI support shipped in 3.0"
35+ )
3336async def test_basic (sentry_init , capture_events , application ):
3437 sentry_init (
3538 integrations = [DjangoIntegration ()],
@@ -579,6 +582,9 @@ async def test_asgi_request_body(
579582 "asyncio.iscoroutinefunction has been replaced in 3.12 by inspect.iscoroutinefunction"
580583 ),
581584)
585+ @pytest .mark .skipif (
586+ django .VERSION < (3 , 0 ), reason = "Django ASGI support shipped in 3.0"
587+ )
582588async def test_asgi_mixin_iscoroutinefunction_before_3_12 ():
583589 sentry_asgi_mixin = _asgi_middleware_mixin_factory (lambda : None )
584590
@@ -636,6 +642,9 @@ def get_response(): ...
636642
637643@pytest .mark .parametrize ("application" , APPS )
638644@pytest .mark .asyncio
645+ @pytest .mark .skipif (
646+ django .VERSION < (3 , 1 ), reason = "async views have been introduced in Django 3.1"
647+ )
639648async def test_async_view (sentry_init , capture_events , application ):
640649 sentry_init (
641650 integrations = [DjangoIntegration ()],
@@ -655,6 +664,9 @@ async def test_async_view(sentry_init, capture_events, application):
655664
656665@pytest .mark .parametrize ("application" , APPS )
657666@pytest .mark .asyncio
667+ @pytest .mark .skipif (
668+ django .VERSION < (3 , 0 ), reason = "Django ASGI support shipped in 3.0"
669+ )
658670async def test_transaction_http_method_default (
659671 sentry_init , capture_events , application
660672):
@@ -687,6 +699,9 @@ async def test_transaction_http_method_default(
687699
688700@pytest .mark .parametrize ("application" , APPS )
689701@pytest .mark .asyncio
702+ @pytest .mark .skipif (
703+ django .VERSION < (3 , 0 ), reason = "Django ASGI support shipped in 3.0"
704+ )
690705async def test_transaction_http_method_custom (sentry_init , capture_events , application ):
691706 sentry_init (
692707 integrations = [
0 commit comments