Skip to content

Commit fff1854

Browse files
.
1 parent 7a10436 commit fff1854

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

tests/integrations/django/test_cache_module.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ def use_django_caching_with_cluster(settings):
9090
}
9191

9292

93+
@pytest.mark.forked
9394
@pytest_mark_django_db_decorator()
9495
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
9596
def test_cache_spans_disabled_middleware(
@@ -115,6 +116,7 @@ def test_cache_spans_disabled_middleware(
115116
assert len(second_event["spans"]) == 0
116117

117118

119+
@pytest.mark.forked
118120
@pytest_mark_django_db_decorator()
119121
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
120122
def test_cache_spans_disabled_decorator(
@@ -140,6 +142,7 @@ def test_cache_spans_disabled_decorator(
140142
assert len(second_event["spans"]) == 0
141143

142144

145+
@pytest.mark.forked
143146
@pytest_mark_django_db_decorator()
144147
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
145148
def test_cache_spans_disabled_templatetag(
@@ -165,6 +168,7 @@ def test_cache_spans_disabled_templatetag(
165168
assert len(second_event["spans"]) == 0
166169

167170

171+
@pytest.mark.forked
168172
@pytest_mark_django_db_decorator()
169173
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
170174
def test_cache_spans_middleware(
@@ -234,6 +238,7 @@ def test_cache_spans_middleware(
234238
assert second_event["spans"][1]["data"]["cache.item_size"] == 58
235239

236240

241+
@pytest.mark.forked
237242
@pytest_mark_django_db_decorator()
238243
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
239244
def test_cache_spans_decorator(sentry_init, client, capture_events, use_django_caching):
@@ -288,6 +293,7 @@ def test_cache_spans_decorator(sentry_init, client, capture_events, use_django_c
288293
assert second_event["spans"][1]["data"]["cache.item_size"] == 58
289294

290295

296+
@pytest.mark.forked
291297
@pytest_mark_django_db_decorator()
292298
@pytest.mark.skipif(DJANGO_VERSION < (1, 9), reason="Requires Django >= 1.9")
293299
def test_cache_spans_templatetag(
@@ -380,6 +386,7 @@ def test_cache_spans_get_span_description(
380386
assert _get_span_description(method_name, args, kwargs) == expected_description
381387

382388

389+
@pytest.mark.forked
383390
@pytest_mark_django_db_decorator()
384391
def test_cache_spans_location_with_port(
385392
sentry_init, client, capture_events, use_django_caching_with_port
@@ -407,6 +414,7 @@ def test_cache_spans_location_with_port(
407414
assert span["data"]["network.peer.port"] == 6379
408415

409416

417+
@pytest.mark.forked
410418
@pytest_mark_django_db_decorator()
411419
def test_cache_spans_location_without_port(
412420
sentry_init, client, capture_events, use_django_caching_without_port
@@ -432,6 +440,7 @@ def test_cache_spans_location_without_port(
432440
assert "network.peer.port" not in span["data"]
433441

434442

443+
@pytest.mark.forked
435444
@pytest_mark_django_db_decorator()
436445
def test_cache_spans_location_with_cluster(
437446
sentry_init, client, capture_events, use_django_caching_with_cluster
@@ -458,6 +467,7 @@ def test_cache_spans_location_with_cluster(
458467
assert "network.peer.port" not in span["data"].keys()
459468

460469

470+
@pytest.mark.forked
461471
@pytest_mark_django_db_decorator()
462472
def test_cache_spans_item_size(sentry_init, client, capture_events, use_django_caching):
463473
sentry_init(
@@ -499,6 +509,7 @@ def test_cache_spans_item_size(sentry_init, client, capture_events, use_django_c
499509
assert second_event["spans"][1]["data"]["cache.item_size"] == 58
500510

501511

512+
@pytest.mark.forked
502513
@pytest_mark_django_db_decorator()
503514
def test_cache_spans_get_many(sentry_init, capture_events, use_django_caching):
504515
sentry_init(
@@ -547,6 +558,7 @@ def test_cache_spans_get_many(sentry_init, capture_events, use_django_caching):
547558
assert transaction["spans"][6]["description"] == f"S{id + 1}"
548559

549560

561+
@pytest.mark.forked
550562
@pytest_mark_django_db_decorator()
551563
def test_cache_spans_set_many(sentry_init, capture_events, use_django_caching):
552564
sentry_init(
@@ -585,6 +597,7 @@ def test_cache_spans_set_many(sentry_init, capture_events, use_django_caching):
585597
assert transaction["spans"][3]["description"] == f"S{id}"
586598

587599

600+
@pytest.mark.forked
588601
@pytest_mark_django_db_decorator()
589602
@pytest.mark.skipif(DJANGO_VERSION <= (1, 11), reason="Requires Django > 1.11")
590603
def test_span_origin_cache(sentry_init, client, capture_events, use_django_caching):

tests/integrations/django/test_data_scrubbing.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ def client():
1818
return Client(application)
1919

2020

21+
@pytest.mark.forked
2122
@pytest_mark_django_db_decorator()
2223
def test_scrub_django_session_cookies_removed(
2324
sentry_init,
@@ -35,6 +36,7 @@ def test_scrub_django_session_cookies_removed(
3536
assert "cookies" not in event["request"]
3637

3738

39+
@pytest.mark.forked
3840
@pytest_mark_django_db_decorator()
3941
def test_scrub_django_session_cookies_filtered(
4042
sentry_init,
@@ -56,6 +58,7 @@ def test_scrub_django_session_cookies_filtered(
5658
}
5759

5860

61+
@pytest.mark.forked
5962
@pytest_mark_django_db_decorator()
6063
def test_scrub_django_custom_session_cookies_filtered(
6164
sentry_init,

0 commit comments

Comments
 (0)