Browse Source

Update pagination tests

pull/697/head
Paul Robert Lloyd 3 years ago
parent
commit
cb3ed044b3
  1. 4
      spec/requests/case_logs_controller_spec.rb
  2. 4
      spec/requests/organisations_controller_spec.rb
  3. 12
      spec/requests/schemes_controller_spec.rb

4
spec/requests/case_logs_controller_spec.rb

@ -548,7 +548,7 @@ RSpec.describe CaseLogsController, type: :request do
end
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).not_to have_content("Previous")
expect(page).not_to have_link("Previous")
expect(page).to have_content("Next")
expect(page).to have_link("Next")
@ -575,7 +575,7 @@ RSpec.describe CaseLogsController, type: :request do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).to have_link("Previous")
expect(page).to have_content("Next")
expect(page).not_to have_content("Next")
expect(page).not_to have_link("Next")
end

4
spec/requests/organisations_controller_spec.rb

@ -874,7 +874,7 @@ RSpec.describe OrganisationsController, type: :request do
context "when on the first page" do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).not_to have_content("Previous")
expect(page).not_to have_link("Previous")
expect(page).to have_content("Next")
expect(page).to have_link("Next")
@ -901,7 +901,7 @@ RSpec.describe OrganisationsController, type: :request do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).to have_link("Previous")
expect(page).to have_content("Next")
expect(page).not_to have_content("Next")
expect(page).not_to have_link("Next")
end

12
spec/requests/schemes_controller_spec.rb

@ -102,7 +102,7 @@ RSpec.describe SchemesController, type: :request do
end
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).not_to have_content("Previous")
expect(page).not_to have_link("Previous")
expect(page).to have_content("Next")
expect(page).to have_link("Next")
@ -121,7 +121,7 @@ RSpec.describe SchemesController, type: :request do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).to have_link("Previous")
expect(page).to have_content("Next")
expect(page).not_to have_content("Next")
expect(page).not_to have_link("Next")
end
@ -334,7 +334,7 @@ RSpec.describe SchemesController, type: :request do
end
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).not_to have_content("Previous")
expect(page).not_to have_link("Previous")
expect(page).to have_content("Next")
expect(page).to have_link("Next")
@ -358,7 +358,7 @@ RSpec.describe SchemesController, type: :request do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).to have_link("Previous")
expect(page).to have_content("Next")
expect(page).not_to have_content("Next")
expect(page).not_to have_link("Next")
end
end
@ -416,7 +416,7 @@ RSpec.describe SchemesController, type: :request do
end
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).not_to have_content("Previous")
expect(page).not_to have_link("Previous")
expect(page).to have_content("Next")
expect(page).to have_link("Next")
@ -440,7 +440,7 @@ RSpec.describe SchemesController, type: :request do
it "has pagination links" do
expect(page).to have_content("Previous")
expect(page).to have_link("Previous")
expect(page).to have_content("Next")
expect(page).not_to have_content("Next")
expect(page).not_to have_link("Next")
end
end

Loading…
Cancel
Save