Skip to content

Commit

Permalink
Add percy snapshot for resend confirmation page
Browse files Browse the repository at this point in the history
  • Loading branch information
mlandauer committed Feb 27, 2024
1 parent 8b59ded commit 94d7c25
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions spec/features/user_sign_up_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
require "spec_helper"

describe "Signing up for an API account" do
include Devise::Test::IntegrationHelpers

it "Successfully signing up", truncation: true do
visit "/api/howto"
click_link "Register for an account"
Expand All @@ -20,4 +22,22 @@
expect(current_email).to have_subject("PlanningAlerts: Confirmation instructions")
expect(current_email.default_part_body.to_s).to include("Please confirm your account email by clicking the link below")
end

describe "resending confirmation instructions in new design" do
before do
sign_in create(:confirmed_user, tailwind_theme: true)
sign_out :user
visit new_user_confirmation_path
end

it "shows the page" do
expect(page).to have_content("Resend confirmation instructions")
end

# rubocop:disable RSpec/NoExpectationExample
it "renders the page", js: true do
page.percy_snapshot("Resend confirmation")
end
# rubocop:enable RSpec/NoExpectationExample
end
end

0 comments on commit 94d7c25

Please sign in to comment.