Skip to content
This repository has been archived by the owner on Nov 30, 2024. It is now read-only.

Commit

Permalink
Update lib/rspec/support/differ.rb
Browse files Browse the repository at this point in the history
Co-authored-by: Jon Rowe <[email protected]>
  • Loading branch information
pirj and JonRowe authored Jun 27, 2024
1 parent 7046659 commit 6b7ff69
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/rspec/support/differ.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def diff_as_string(actual, expected)
if defined?(RSpec::Mocks::ArgumentMatchers::AnyArgMatcher)
def diff_hashes_as_object(actual, expected)
actual_to_diff =
actual.reduce({}) do |hash, (key, value)|
actual.keys.reduce({}) do |hash, key|
if RSpec::Mocks::ArgumentMatchers::AnyArgMatcher === expected[key]
hash[key] = expected[key]
else
Expand Down

0 comments on commit 6b7ff69

Please sign in to comment.