Skip to content

Commit 31a0efd

Browse files
committed
actually test an error to make sure we can capture
1 parent 2782309 commit 31a0efd

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

tests/integrations/quart/test_quart.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,14 +89,18 @@ async def test_quart_flask_patch(sentry_init, capture_events, reset_integrations
8989

9090
@app.route("/")
9191
async def index():
92-
return "ok"
92+
1 / 0
9393

9494
events = capture_events()
9595

9696
client = app.test_client()
97-
await client.get("/")
97+
try:
98+
await client.get("/")
99+
except ZeroDivisionError:
100+
pass
98101

99-
assert not events
102+
(event,) = events
103+
assert event["exception"]["values"][0]["mechanism"]["type"] == "quart"
100104

101105

102106
@pytest.mark.asyncio

0 commit comments

Comments
 (0)