Skip to content

Commit

Permalink
bypass sign_user_in helper for readability;
Browse files Browse the repository at this point in the history
  • Loading branch information
strouptl committed Jun 5, 2024
1 parent 6e70818 commit 6e06121
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion test/integration/refresh_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,13 @@ def teardown
admin.populate_otp_secrets!
admin.enable_otp!

sign_user_in(admin)
visit new_admin_session_path
fill_in "admin_email", with: admin.email
fill_in "admin_password", with: admin.password

page.has_content?("Log in") ? click_button("Log in") : click_button("Sign in")

assert_equal admin_otp_credential_path, current_path

fill_in "admin_token", with: ROTP::TOTP.new(admin.otp_auth_secret).at(Time.now)
click_button "Submit Token"
Expand Down

0 comments on commit 6e06121

Please sign in to comment.