Skip to content

Commit

Permalink
Add headless_chrome_driver to test setup
Browse files Browse the repository at this point in the history
  • Loading branch information
jenshenny committed May 6, 2022
1 parent 0c1c58c commit e7a1eca
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions test/integration/api_keys_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

class ApiKeysTest < SystemTest
setup do
headless_chrome_driver
@user = create(:user)
@ownership = create(:ownership, user: @user, rubygem: create(:rubygem))

Expand Down Expand Up @@ -168,6 +169,7 @@ class ApiKeysTest < SystemTest
visit_profile_api_keys_path
click_button "Delete"

page.accept_alert
assert page.has_content? "New API key"
end

Expand All @@ -177,6 +179,7 @@ class ApiKeysTest < SystemTest
visit_profile_api_keys_path
click_button "Reset"

page.accept_alert
assert page.has_content? "New API key"
end

Expand Down Expand Up @@ -213,4 +216,9 @@ def verify_password
fill_in "Password", with: PasswordHelpers::SECURE_TEST_PASSWORD
click_button "Confirm"
end

teardown do
Capybara.reset_sessions!
Capybara.use_default_driver
end
end

0 comments on commit e7a1eca

Please sign in to comment.