Skip to content
This repository has been archived by the owner on Oct 16, 2024. It is now read-only.

Commit

Permalink
close rabbitmq connections on teardown
Browse files Browse the repository at this point in the history
  • Loading branch information
javierdelapuente committed Sep 11, 2024
1 parent f266001 commit 8fbcc59
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions examples/flask/test_rock/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,12 @@ def teardown_database(_):
boto3_client = g.pop("boto3_client", None)
if boto3_client is not None:
boto3_client.close()
rabbitmq = g.pop("rabbitmq", None)
if rabbitmq is not None:
rabbitmq.close()
rabbitmq_from_uri = g.pop("rabbitmq_from_uri", None)
if rabbitmq_from_uri is not None:
rabbitmq_from_uri.close()


@app.route("/")
Expand Down

0 comments on commit 8fbcc59

Please sign in to comment.