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 matcher in custom matcher with expect syntax #725

Closed
hgmnz opened this issue Nov 10, 2012 · 7 comments
Closed

match matcher in custom matcher with expect syntax #725

hgmnz opened this issue Nov 10, 2012 · 7 comments

Comments

@hgmnz
Copy link

hgmnz commented Nov 10, 2012

..that's a mouthful.

Basically, If I'm using the new expect synthax, and I define a custom matcher that utilizes the match matcher, there is an unexpected issue with wrong number of arguments.

Here's a small example reproducing the problem:

https://gist.github.com/4937936fe14adeddcc9d

@vanstee
Copy link

vanstee commented Nov 10, 2012

Looks like after trying to define match it's still using the method defined in rspec-expectations:

method(:match).source_location # => [".../rspec-expectations-2.11.3/lib/rspec/matchers.rb", 494]

https://github.com/rspec/rspec-expectations/blob/master/lib/rspec/matchers.rb#L494-496

@hgmnz
Copy link
Author

hgmnz commented Nov 10, 2012

Ah, thanks for verifying!

@hgmnz
Copy link
Author

hgmnz commented Nov 12, 2012

This issue was tagged as wrongtracker. Should this be on the rspec/rspec-expectations tracker and am I expect to move it?

@dchelimsky
Copy link
Contributor

@hgmnz I'm not sure who flagged it as wrong tracker, but yes, it does belong in rspec-expectations. As for who is responsible to move it, it's better if you close this one and open a new one there so you can find it easily later in the other tracker (under issues created by you). Happy to move it myself if you don't care about that.

@hgmnz
Copy link
Author

hgmnz commented Nov 12, 2012

@dchelimsky thanks, moved it to rspec/rspec-expectations#188

@hgmnz hgmnz closed this as completed Nov 12, 2012
@dchelimsky
Copy link
Contributor

@hgmnz thank you!

@hgmnz
Copy link
Author

hgmnz commented Nov 12, 2012

@dchelimsky no, thank you! 🎁

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

3 participants