Add spec demonstrating odd `method_missing` behavior. #183

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
3 participants
Owner

myronmarston commented Oct 23, 2012

I ran into this in some rspec-mocks specs for rspec/rspec-mocks#23 but traced it back to rspec-expectations. This isn't meant to be merged yet (we need to solve the issue first) but I wanted to at least document the issue with a failing spec.

It's very, very odd...I put comments in the example that explain it in detail.

Anyone want to take a stab at troubleshooting this?

Add spec demonstrating odd `method_missing` behavior.
I ran into this in some rspec-mocks specs but traced it back to rspec-expectations.
Contributor

alindeman commented Oct 24, 2012

That is really weird. I dug in for a few minutes to no avail, but will try to revisit soon.

Owner

myronmarston commented Oct 24, 2012

@alindeman -- thanks for trying at least.

Owner

myronmarston commented Jan 13, 2013

I just ran across an old blog post of yehuda's:

http://yehudakatz.com/2010/01/02/the-craziest-fing-bug-ive-ever-seen/

It looks like it may be the same issue we hit here.

Owner

JonRowe commented Mar 5, 2013

Did you make any progress on tracking this down?

Owner

myronmarston commented Mar 5, 2013

Not yet. I suspect it's just a ruby bug, that we can't do anything about.

Owner

JonRowe commented Mar 6, 2013

Interestingly, when I tried to replicate this outside of the RSpec test suite, I discovered the including RSpec::Matchers into object before any specs fixes the issue... see https://gist.github.com/JonRowe/5095746

Owner

myronmarston commented Feb 27, 2014

Closing. This doesn't seem to actually matter for end users but is odd.

@myronmarston myronmarston deleted the method_missing_strangeness branch Feb 27, 2014

@myronmarston myronmarston restored the method_missing_strangeness branch Feb 27, 2014

Owner

myronmarston commented Feb 27, 2014

I'm keeping the branch around for potential future use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment