mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-11 22:51:28 +00:00
Update tests/logging_callback_tests/test_gcs_pub_sub.py
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
This commit is contained in:
parent
47fea2acdf
commit
aeae28bda3
1 changed files with 1 additions and 0 deletions
|
|
@ -82,6 +82,7 @@ def extract_pubsub_payload(mock_post: AsyncMock) -> dict:
|
|||
Handles base64 decoding of the Pub/Sub message data.
|
||||
"""
|
||||
actual_request = mock_post.call_args[1]["json"]
|
||||
assert "messages" in actual_request, f"Expected 'messages' key in Pub/Sub request, got keys: {list(actual_request.keys())}"
|
||||
encoded_message = actual_request["messages"][0]["data"]
|
||||
decoded_message = base64.b64decode(encoded_message).decode("utf-8")
|
||||
return json.loads(decoded_message)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue