From cc8330978e0833f39189420f12611fd3d8249a02 Mon Sep 17 00:00:00 2001 From: baarkerlounger Date: Wed, 1 Dec 2021 17:33:43 +0000 Subject: [PATCH] Turning off turbo changes our html --- app/views/organisations/users.html.erb | 2 +- spec/requests/organisations_controller_spec.rb | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/app/views/organisations/users.html.erb b/app/views/organisations/users.html.erb index d46b1ea32..99b720ec2 100644 --- a/app/views/organisations/users.html.erb +++ b/app/views/organisations/users.html.erb @@ -2,7 +2,7 @@ <%= "Users" %> <% end %> -<%= govuk_button_link_to "Invite user", new_user_registration_path, html: { "data-turbo" => "false" , method: :get } %> +<%= govuk_button_link_to "Invite user", new_user_registration_path, html: { "data-turbo" => "false", method: :get } %> <%= govuk_table do |table| %> <%= table.head do |head| %> <%= head.row do |row| diff --git a/spec/requests/organisations_controller_spec.rb b/spec/requests/organisations_controller_spec.rb index 3239dafbf..cd07845ac 100644 --- a/spec/requests/organisations_controller_spec.rb +++ b/spec/requests/organisations_controller_spec.rb @@ -4,6 +4,7 @@ RSpec.describe OrganisationsController, type: :request do let(:user) { FactoryBot.create(:user) } let(:organisation) { user.organisation } let(:headers) { { "Accept" => "text/html" } } + let(:page) { Capybara::Node::Simple.new(response.body) } context "details tab" do before do @@ -40,9 +41,7 @@ RSpec.describe OrganisationsController, type: :request do end it "shows a new user button" do - expected_html = "