Sha256: 1fb345bc927e3e5e6d18c152b35902fcbb8df3048e7cf940ede1316d44324cb8
Contents?: true
Size: 654 Bytes
Versions: 2
Compression:
Stored size: 654 Bytes
Contents
require 'test_helper' require 'integration_tests_helper' class TokenTest < ActionDispatch::IntegrationTest def teardown Capybara.reset_sessions! end test 'disabling OTP after successfully enabling' do # log in 1fa user = enable_otp_and_sign_in assert_equal user_otp_credential_path, current_path # otp 2fa fill_in 'user_token', :with => ROTP::TOTP.new(user.otp_auth_secret).at(Time.now) click_button 'Submit Token' assert_equal root_path, current_path # disable OTP disable_otp # logout sign_out # log back in 1fa sign_user_in(user) assert_equal root_path, current_path end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
devise-otp-0.4.0 | test/integration/token_test.rb |
devise-otp-0.3.0 | test/integration/token_test.rb |