summaryrefslogtreecommitdiff
path: root/spec/support/shared_examples/requests/get_request.rb
blob: c40219632a2ff0e9680b8b43180e3c8a5481da97 (plain)
1
2
3
4
5
6
7
8
9
10
11
# frozen_string_literal: true

RSpec.shared_examples 'a GET request' do
  context 'for an existing resource' do
    it 'returns a 200 status and the requested resource(s)'do
      get(route, headers:)
      expect(response).to have_http_status(200)
      expect(response.body).to include_strings(expected_text)
    end
  end
end