0

How do you stub a call to get_object using a client & encrypted client? Goal is to write rspec tests to get_object using the following clients. Does anyone have a "get_object" working example they can share? I am aware of various web pages that describe aws-sdk-ruby stubs but haven't been able to get anything working.

Aws::S3::Client.new
Aws::S3::Encryption::Client.new

1 Answers1

1

Referring to this blog post you can use

# stub everything
Aws.config[:stub_responses] = true

which is supposed to prevent all http call.

GPif
  • 543
  • 2
  • 6
  • 22