Sha256: 4baed0f16f727e6c29404c8bce41dbfc422bdc71f6fd1c97f3624931dd942617
Contents?: true
Size: 727 Bytes
Versions: 14
Compression:
Stored size: 727 Bytes
Contents
require "rambo_helper" RSpec.describe "e-BookMobile API", type: :request do describe "/authors" do let(:route) { "/authors" } describe "GET" do let(:response_schema) do File.read("spec/support/examples/authors_response_schema.json") end let(:output_file) do "spec/contract/output/authors_get_response.json" end it "retrieve a list of authors" do get route File.open(output_file, "w+") {|file| file.puts JSON.pretty_generate(JSON.parse(response.body)) } expect(response.body).to match_schema response_schema end it "returns status 200" do get route expect(response.status).to eql 200 end end end end
Version data entries
14 entries across 14 versions & 1 rubygems