diff --git a/features/desktop/change_password.feature b/features/desktop/change_password.feature index 4b20caa56b69af1f7436c6020be7e63144252922..8096c22d596359f825dc412f996e0716fc4b1300 100644 --- a/features/desktop/change_password.feature +++ b/features/desktop/change_password.feature @@ -27,8 +27,8 @@ Feature: Change password And I submit forgot password form Then I should see "You will receive an email with instructions" When I follow the "Change my password" link from the last sent email - When I fill out reset password form with "supersecret" and "supersecret" - And I submit reset password form + When I fill out the password reset form with "supersecret" and "supersecret" + And I submit the password reset form Then I should be on the stream page And I sign out manually And I sign in manually as "georges_abitbol" with password "supersecret" @@ -40,7 +40,7 @@ Feature: Change password When I fill out forgot password form with "forgetful@users.net" And I submit forgot password form When I follow the "Change my password" link from the last sent email - When I fill out reset password form with "too" and "short" + When I fill out the password reset form with "too" and "short" And I press "Change my password" Then I should be on the user password page And I should see "Password is too short" diff --git a/features/mobile/change_password.feature b/features/mobile/change_password.feature index 925e3587c1d902cc9ff886a35547f417766c31fd..0bd6e70b44af22675900d8476a367c6353598886 100644 --- a/features/mobile/change_password.feature +++ b/features/mobile/change_password.feature @@ -29,8 +29,8 @@ Feature: Change password And I submit forgot password form Then I should see "You will receive an email with instructions" When I follow the "Change my password" link from the last sent email - And I fill out reset password form with "supersecret" and "supersecret" - And I submit reset password form + And I fill out the password reset form with "supersecret" and "supersecret" + And I submit the password reset form Then I should be on the stream page When I sign out manually on the mobile website And I sign in manually as "georges_abitbol" with password "supersecret" on the mobile website @@ -42,7 +42,7 @@ Feature: Change password When I fill out forgot password form with "forgetful@users.net" And I submit forgot password form And I follow the "Change my password" link from the last sent email - And I fill out reset password form with "too" and "short" + And I fill out the password reset form with "too" and "short" And I press "Change my password" Then I should be on the user password page And I should see "Password is too short" diff --git a/features/step_definitions/session_steps.rb b/features/step_definitions/session_steps.rb index 69ee9d6fd153e7f0134e8758b6d4741384b38b25..320c09831afaa748e6cac91eda2094383203dbf5 100644 --- a/features/step_definitions/session_steps.rb +++ b/features/step_definitions/session_steps.rb @@ -57,12 +57,12 @@ When /^I submit forgot password form$/ do submit_forgot_password_form end -When /^I fill out reset password form with "([^"]*)" and "([^"]*)"$/ do |new_pass,confirm_pass| - fill_reset_password_form(new_pass, confirm_pass) +When /^I fill out the password reset form with "([^"]*)" and "([^"]*)"$/ do |new_pass,confirm_pass| + fill_password_reset_form(new_pass, confirm_pass) end -When /^I submit reset password form$/ do - submit_reset_password_form +When /^I submit the password reset form$/ do + submit_password_reset_form end When /^I (?:log|sign) out$/ do diff --git a/features/support/user_cuke_helpers.rb b/features/support/user_cuke_helpers.rb index cd2cc1ca11e61517a0a8e65f2783b3144c288080..3a94912b7c9719e60e8b90350b81c1e7cd2d2ba7 100644 --- a/features/support/user_cuke_helpers.rb +++ b/features/support/user_cuke_helpers.rb @@ -98,14 +98,14 @@ module UserCukeHelpers find("#new_user input.btn").click end - # fill the reset password form - def fill_reset_password_form(new_pass, confirm_pass) + # fill the password reset form + def fill_password_reset_form(new_pass, confirm_pass) fill_in 'user_password', :with => new_pass fill_in 'user_password_confirmation', :with => confirm_pass end - # submit reset password form - def submit_reset_password_form + # submit the password reset form + def submit_password_reset_form find(".btn").click end