should receiving stubbed atleast_once removes matching stub(Issue 103) #110

Merged
merged 2 commits into from Feb 24, 2012

Conversation

Projects
None yet
2 participants
@preethiramdev
Contributor

preethiramdev commented Feb 20, 2012

No description provided.

@preethiramdev

This comment has been minimized.

Show comment Hide comment
@preethiramdev

preethiramdev Feb 23, 2012

Contributor

@dchelimsky I would love to do some work on any feature requests or other stuff that you may have in the pipeline. Having worked on a couple of bugs I feel familiar enough with the rspec-mocks code to try my hand at it. I did follow your earlier suggestion of picking up bugs but am running out of them and have now moved to rspec-core/ rspec-expectations :)

Contributor

preethiramdev commented Feb 23, 2012

@dchelimsky I would love to do some work on any feature requests or other stuff that you may have in the pipeline. Having worked on a couple of bugs I feel familiar enough with the rspec-mocks code to try my hand at it. I did follow your earlier suggestion of picking up bugs but am running out of them and have now moved to rspec-core/ rspec-expectations :)

@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Feb 23, 2012

Member

After merging this I see the following warnings:

An expectation of :random_call was set on nil. Called from /Users/david/projects/ruby/rspec2/repos/rspec-mocks/spec/rspec/mocks/stubbed_message_expectations_spec.rb:48:in `block (3 levels) in <top (required)>'. Use allow_message_expectations_on_nil to disable warnings.
An expectation of :random_call was set on nil. Called from /Users/david/projects/ruby/rspec2/repos/rspec-mocks/spec/rspec/mocks/stubbed_message_expectations_spec.rb:49:in `block (3 levels) in <top (required)>'. Use allow_message_expectations_on_nil to disable warnings.

Please fix and I'll look again.

Member

dchelimsky commented Feb 23, 2012

After merging this I see the following warnings:

An expectation of :random_call was set on nil. Called from /Users/david/projects/ruby/rspec2/repos/rspec-mocks/spec/rspec/mocks/stubbed_message_expectations_spec.rb:48:in `block (3 levels) in <top (required)>'. Use allow_message_expectations_on_nil to disable warnings.
An expectation of :random_call was set on nil. Called from /Users/david/projects/ruby/rspec2/repos/rspec-mocks/spec/rspec/mocks/stubbed_message_expectations_spec.rb:49:in `block (3 levels) in <top (required)>'. Use allow_message_expectations_on_nil to disable warnings.

Please fix and I'll look again.

@preethiramdev

This comment has been minimized.

Show comment Hide comment
@preethiramdev

preethiramdev Feb 24, 2012

Contributor

commit 251bf2a should fix this

Contributor

preethiramdev commented Feb 24, 2012

commit 251bf2a should fix this

dchelimsky added a commit that referenced this pull request Feb 24, 2012

Merge pull request #110 from c42engineering/issue-103
should_receive(:x).at_least_once clears any stubs on :x

- Fixes #103

@dchelimsky dchelimsky merged commit 6e23ca9 into rspec:master Feb 24, 2012

dchelimsky added a commit that referenced this pull request Feb 24, 2012

Revert "Merge pull request #110 from c42engineering/issue-103"
Turns out this change is significantly backward-incompatible that we're
going to have to wait for rspec-mocks-3 to release it (or similar)

This reverts commit 6e23ca9, reversing
changes made to 117f2cb.
@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Feb 24, 2012

Member

After merging this I explored it a bit more and realize that this is more of a breaking change than is appropriate for a 2.x release. Going to have to wait for 3.0 if we do it at all.

Member

dchelimsky commented Feb 24, 2012

After merging this I explored it a bit more and realize that this is more of a breaking change than is appropriate for a 2.x release. Going to have to wait for 3.0 if we do it at all.

@dchelimsky

This comment has been minimized.

Show comment Hide comment
@dchelimsky

dchelimsky Feb 24, 2012

Member

Note that github offers me no option to re-open this :(

Member

dchelimsky commented Feb 24, 2012

Note that github offers me no option to re-open this :(

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