Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

match_array with single element does not match Rspec behaviour #97

Closed
Mongey opened this issue Aug 6, 2020 · 2 comments
Closed

match_array with single element does not match Rspec behaviour #97

Mongey opened this issue Aug 6, 2020 · 2 comments

Comments

@Mongey
Copy link

Mongey commented Aug 6, 2020

This is valid when super_diff is not installed.

  expect(ids).to match_array(single_id)

With super_diff installed it fails with

Failure/Error: expect(ids).to match_array(single_id)

NoMethodError:
  undefined method `each_with_index' for "my_id":String
  Did you mean?  each_line

I had to update the test to

-        expect(ids).to match_array(single_id)
+        expect(ids).to match_array([single_id])
@mcmire
Copy link
Collaborator

mcmire commented Aug 6, 2020

Okay, thanks! I'll check it out and see what's up here.

guiferrpereira added a commit to guiferrpereira/super_diff that referenced this issue Dec 11, 2020
@mcmire
Copy link
Collaborator

mcmire commented Feb 14, 2021

This is fixed in 0.5.3+! Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants