Skip to content

Commit 13c96be

Browse files
committed
Make test fail easier
1 parent 3e9a012 commit 13c96be

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

tests/integrations/aiohttp/test_aiohttp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -541,7 +541,7 @@ async def handler(request):
541541
client = await aiohttp_client(raw_server)
542542
resp = await client.get("/")
543543

544-
envelope = envelopes[0]
544+
(envelope,) = envelopes
545545
transaction = envelope.get_transaction_event()
546546
request_span = transaction["spans"][-1]
547547

tests/integrations/httpx/test_httpx.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ def test_outgoing_trace_headers(sentry_init, httpx_client, capture_envelopes):
8484
else:
8585
response = httpx_client.get(url)
8686

87-
envelope = envelopes[0]
87+
(envelope,) = envelopes
8888
transaction = envelope.get_transaction_event()
8989
request_span = transaction["spans"][-1]
9090

@@ -127,7 +127,7 @@ def test_outgoing_trace_headers_append_to_baggage(
127127
else:
128128
response = httpx_client.get(url, headers={"baGGage": "custom=data"})
129129

130-
envelope = envelopes[0]
130+
(envelope,) = envelopes
131131
transaction = envelope.get_transaction_event()
132132
request_span = transaction["spans"][-1]
133133

tests/integrations/stdlib/test_httplib.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ def test_outgoing_trace_headers(sentry_init, monkeypatch, capture_envelopes):
165165
key, val = line.split(": ")
166166
request_headers[key] = val
167167

168-
envelope = envelopes[0]
168+
(envelope,) = envelopes
169169
transaction = envelope.get_transaction_event()
170170
request_span = transaction["spans"][-1]
171171

@@ -212,7 +212,7 @@ def test_outgoing_trace_headers_head_sdk(sentry_init, monkeypatch, capture_envel
212212
key, val = line.split(": ")
213213
request_headers[key] = val
214214

215-
envelope = envelopes[0]
215+
(envelope,) = envelopes
216216
transaction = envelope.get_transaction_event()
217217
request_span = transaction["spans"][-1]
218218

0 commit comments

Comments
 (0)