Sha256: d9169c85148dce781fb2900ac6b0c1772571e9147a1ee5d3d55de3c9d1d07b5b

Contents?: true

Size: 783 Bytes

Versions: 18

Compression:

Stored size: 783 Bytes

Contents

require "application_system_test_case"

class Identity::PasswordResetsTest < ApplicationSystemTestCase
  setup do
    @user = users(:lazaro_nixon)
    @sid = @user.signed_id(purpose: :password_reset, expires_in: 20.minutes)
  end

  test "sending a password reset email" do
    visit sign_in_url
    click_on "Forgot your password?"

    fill_in "Email", with: @user.email
    click_on "Send password reset email"

    assert_text "Check your email for reset instructions"
  end

  test "updating password" do
    visit edit_identity_password_reset_url(token: @sid)

    fill_in "New password", with: "Secret6*4*2*"
    fill_in "Confirm new password", with: "Secret6*4*2*"
    click_on "Save changes"

    assert_text "Your password was reset successfully. Please sign in"
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
authentication-zero-2.15.8 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.7 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.6 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.5 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.4 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.3 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.2 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.1 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.15.0 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.14.0 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.13.0 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.6 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.5 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.4 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.3 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.2 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.1 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt
authentication-zero-2.12.0 lib/generators/authentication/templates/test_unit/system/identity/password_resets_test.rb.tt