Skip to content

Commit

Permalink
Make tests OpenSSL 3 compatible.
Browse files Browse the repository at this point in the history
  • Loading branch information
simi committed Aug 21, 2022
1 parent e0f9782 commit 23d3cab
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/models/concerns/user_multifactor_methods.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ def mfa_required_weak_level_enabled?

def otp_verified?(otp)
otp = otp.to_s
return false if mfa_seed.blank?
return true if verify_digit_otp(mfa_seed, otp)

return false unless mfa_recovery_codes.include? otp
Expand Down
2 changes: 1 addition & 1 deletion test/unit/pusher_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -582,7 +582,7 @@ def two_cert_chain(signing_key:, root_not_before: Time.current, cert_not_before:
assert_not_nil @cutter.version
assert_not_nil @cutter.version.cert_chain
assert_equal 1, @cutter.version.cert_chain.size
assert_equal "/CN=snakeoil/DC=example/DC=invalid", @cutter.version.cert_chain.first.subject.to_s
assert_equal "CN=snakeoil/DC=example/DC=invalid", @cutter.version.cert_chain.first.subject.to_utf8
end

teardown { RubygemFs.mock! }
Expand Down

0 comments on commit 23d3cab

Please sign in to comment.