Skip to content

Instantly share code, notes, and snippets.

@grantcooksey
grantcooksey / stubber.py
Last active February 8, 2023 11:21
Mocking an S3 bucket using Stubber
import io
import json
import botocore.session
from botocore.stub import Stubber
from botocore.response import StreamingBody
expected_message = {
'message': 'readme'
}