diff --git a/features/change_email.feature b/features/change_email.feature index a5eb2389b..20662ba6d 100644 --- a/features/change_email.feature +++ b/features/change_email.feature @@ -2,11 +2,9 @@ Feature: Change email Scenario: Change my email - Given I am signed in - And I click on my name in the header - And I follow "Settings" - Then I should be on my account settings page - When I fill in "user_email" with "new_email@newplac.es" + Given I am signed in + When I go to the users edit page + And I fill in "user_email" with "new_email@newplac.es" And I press "Change email" Then I should see "Email changed" And I follow the "confirm_email" link from the last sent email diff --git a/features/change_password.feature b/features/change_password.feature index 03daf9364..1115741f9 100644 --- a/features/change_password.feature +++ b/features/change_password.feature @@ -2,11 +2,9 @@ Feature: Change password Scenario: Change my password - Given I am signed in - And I click on my name in the header - And I follow "Settings" - Then I should be on my account settings page - When I put in my password in "user_current_password" + Given I am signed in + When I go to the users edit page + And I put in my password in "user_current_password" And I fill in "user_password" with "newsecret" And I fill in "user_password_confirmation" with "newsecret" And I press "Change password" diff --git a/features/closes_account.feature b/features/closes_account.feature index 91b026dca..fbd174015 100644 --- a/features/closes_account.feature +++ b/features/closes_account.feature @@ -6,8 +6,7 @@ Feature: Close Account Scenario: user closes account Given I am signed in - When I click on my name in the header - And I follow "Settings" + When I go to the users edit page And I follow "Close Account" And I put in my password in "close_account_password" in the modal window And I preemptively confirm the alert @@ -29,9 +28,9 @@ Feature: Close Account And I fill in "status_message_fake_text" with "Hi, @{Bob Jones; bob_jones@example.org} long time no see" And I press "Share" And I log out + Then I sign in as "bob@bob.bob" - When I click on my name in the header - And I follow "Settings" + When I go to the users edit page And I follow "Close Account" And I put in my password in "close_account_password" in the modal window And I preemptively confirm the alert diff --git a/features/step_definitions/custom_web_steps.rb b/features/step_definitions/custom_web_steps.rb index 8a143a4c2..cbb6a0154 100644 --- a/features/step_definitions/custom_web_steps.rb +++ b/features/step_definitions/custom_web_steps.rb @@ -120,7 +120,7 @@ Then /^(?:|I )should not see a "([^\"]*)"(?: within "([^\"]*)")?$/ do |selector, end When /^I wait for the ajax to finish$/ do - wait_until(30) { evaluate_script("$.active") == 0 } + wait_until(15) { evaluate_script("$.active") == 0 } end When /^I have turned off jQuery effects$/ do diff --git a/features/step_definitions/session_steps.rb b/features/step_definitions/session_steps.rb index 808279389..acea6e910 100644 --- a/features/step_definitions/session_steps.rb +++ b/features/step_definitions/session_steps.rb @@ -7,7 +7,6 @@ When /^I try to sign in$/ do @me ||= Factory(:user_with_aspect, :getting_started => false) page.driver.visit(new_integration_sessions_path(:user_id => @me.id)) step %(I press "Login") - step %(I am on the homepage) # To save time as compared to: #step %(I go to the new user session page) #step %(I fill in "Username" with "#{@me.username}") @@ -38,6 +37,5 @@ When /^I put in my password in "([^"]*)"$/ do |field| end When /^I (?:log|sign) out$/ do - step 'I click on my name in the header' - step 'I follow "Log out"' + step %(I go to the destroy user session page) end