Sha256: a1dfff6738c30ae41c4320842c1a7f21c7c66f63b2ab78a3951379fe0b62e518
Contents?: true
Size: 1006 Bytes
Versions: 1
Compression:
Stored size: 1006 Bytes
Contents
require "yaml" require "zlib" require "multi_json" require "minitest/autorun" require "webmock/minitest" require "vcr" require "mocha/setup" require "picasa" AuthHeader = ENV["PICASA_AUTH_HEADER"] || "GoogleLogin auth=token" AccessToken = ENV["PICASA_ACCESS_TOKEN"] || "access-token" MultiJson.adapter = ENV["JSON_PARSER"] || "oj" VCR.configure do |c| c.cassette_library_dir = "test/cassettes" c.hook_into :webmock c.default_cassette_options = {preserve_exact_body_bytes: true} c.filter_sensitive_data("<FILTERED>") { AuthHeader } end class MiniTest::Test def setup WebMock.disable_net_connect! end def fixture_path(filename) File.join("test", "fixtures", filename) end # Retrieves gzipped body def decode(cassette_name) cassette = YAML.load_file(File.join("test", "cassettes", cassette_name)) gzipped_body = cassette["http_interactions"][0]["response"]["body"]["string"] body_io = StringIO.new(gzipped_body) Zlib::GzipReader.new(body_io).read end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
picasa-0.9.1 | test/helper.rb |