Browse Source

tests: add initial test

pull/954/head
natdeanlewissoftwire 3 years ago
parent
commit
aa3e592a6b
  1. 10
      spec/requests/organisations_controller_spec.rb

10
spec/requests/organisations_controller_spec.rb

@ -321,6 +321,16 @@ RSpec.describe OrganisationsController, type: :request do
end end
end end
context "when adding a housing provider" do
before do
get "/organisations/#{organisation.id}/housing-providers/add", headers:, params: {}
end
it "has the correct header" do
expect(response.body).to include("What is the name of your housing provider?")
end
end
context "with an organisation that are not in scope for the user, i.e. that they do not belong to" do context "with an organisation that are not in scope for the user, i.e. that they do not belong to" do
before do before do
get "/organisations/#{unauthorised_organisation.id}/housing-providers", headers:, params: {} get "/organisations/#{unauthorised_organisation.id}/housing-providers", headers:, params: {}

Loading…
Cancel
Save