daily pastebin goal
41%
SHARE
TWEET

resetPassword.feature

ceeKuan Jan 29th, 2018 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. @FE @FE-SignIn @TEST @ignore
  2.  
  3. Feature:[FE] [Sign In] Reset Password
  4.  
  5.   The reset password feature allows users to click the link in the forgotten
  6.   password email and gives them the ability to set a new password. Test cases
  7.   have been written to ensure users cannot use old passwords to log in, as well
  8.   as not being able to enter an invalid new password.
  9.  
  10.   Scenario: The user is unable to reset their password using an invalid password
  11.     Given I have received the reset password email
  12.     When I click the reset password link
  13.  
  14.     Given the Einstein Reset Your Password page is launched (/new-password)
  15.     And I type '123' into the 1st input with the attribute 'password' and the value 'password'
  16.     And I type '123' into the 2nd input with the attribute 'password' and the value 'password'
  17.     Then I cannot click on the Reset Password button with the attribute 'type' and the value 'submit'
  18.  
  19.   Scenario: The user resets their password
  20.     Given I have received the reset password email
  21.     When I click the reset password link
  22.  
  23.     Given the Einstein Reset Your Password page is launched (/new-password)
  24.     And I type '12345678' into the 1st input with the attribute 'password' and the value 'password'
  25.     And I type '12345678' into the 2nd input with the attribute 'password' and the value 'password'
  26.     Then I click on the 'Reset Password' button with the attribute 'type' and the value 'submit'
  27.     And an h1 containing 'Password Reset ???????' appears
  28.  
  29.   Scenario: The user attempts to use their old password to sign in
  30.     Given I have received the reset password email
  31.     When I click the reset password link
  32.  
  33.     Given the Einstein Reset Your Password page is launched (/new-password)
  34.     And I type 'newPassword' into the 1st input with the attribute 'password' and the value 'password'
  35.     And I type 'newPassword' into the 2nd input with the attribute 'password' and the value 'password'
  36.     Then I click on the 'Reset Password' button with the attribute 'type' and the value 'submit'
  37.     And an h1 containing 'Password Reset ???????' appears
  38.  
  39.     Given the Einstein homepage is launched (/)
  40.     When I click on the 'Sign In' button with the XPath '//*[@id="app"]/div/header/section[1]/div[2]/div[7]/button'
  41.     Then the input with the attribute 'name' and the value 'email' exists
  42.     And the input with the attribute 'name' and the value 'password' exists
  43.  
  44.     Then I type 'testing@einstein.exchange' into the input with the attribute 'name' and the value 'email'
  45.     And I type 'oldPassword' into the input with the attribute 'name' and the value 'password'
  46.     Then I click on the 'Sign In' button with the attribute 'type' and the value 'submit'
  47.  
  48.     But the div with the attribute 'message' containing 'Wrong username or password.' exists
  49.  
  50.   Scenario: The user uses their new password to sign in
  51.     Given I have received the reset password email
  52.     When I click the reset password link
  53.  
  54.     Given the Einstein Reset Your Password page is launched (/new-password)
  55.     And I type 'newPassword' into the 1st input with the attribute 'password' and the value 'password'
  56.     And I type 'newPassword' into the 2nd input with the attribute 'password' and the value 'password'
  57.     Then I click on the 'Reset Password' button with the attribute 'type' and the value 'submit'
  58.     And an h1 containing 'Password Reset ???????' appears
  59.  
  60.     Given the Einstein homepage is launched (/)
  61.     When I click on the 'Sign In' button with the XPath '//*[@id="app"]/div/header/section[1]/div[2]/div[7]/button'
  62.     Then the input with the attribute 'name' and the value 'email' exists
  63.     And the input with the attribute 'name' and the value 'password' exists
  64.  
  65.     Then I type 'testing@einstein.exchange' into the input with the attribute 'name' and the value 'email'
  66.     And I type 'newPassword' into the input with the attribute 'name' and the value 'password'
  67.     Then I click on the 'Sign In' button with the attribute 'type' and the value 'submit'
  68.  
  69.     But the div with the attribute 'message' containing 'Wrong username or password.' exists
  70.  
  71.   Scenario: The user uses their current password to sign in after receiving the reset password email
  72.     Given I have received the reset password email
  73.  
  74.     Given the Einstein homepage is launched (/)
  75.     When I click on the 'Sign In' button with the XPath '//*[@id="app"]/div/header/section[1]/div[2]/div[7]/button'
  76.     Then the input with the attribute 'name' and the value 'email' exists
  77.     And the input with the attribute 'name' and the value 'password' exists
  78.  
  79.     Then I type 'testing@einstein.exchange' into the 'email' input titled 'Email Address' with the attribute 'name'
  80.     And I type 'currentPassword' into the 'password' input titled 'Password' with the attribute 'name'
  81.     Then I click on the 'Sign In' button with the attribute 'type' and the value 'submit'
  82.  
  83.     Then the 'My Dashboard' page loads (/my-dashboard)
RAW Paste Data
Pastebin PRO WINTER Special!
Get 40% OFF Pastebin PRO accounts!
Top