Nevermind. If I would have waited five more minutes before clicking
"Send", I would have seen my error.
Blech.
Phillip Koebbe wrote:
What is the expected behavior when a model has both stub and
should_receive defined for the same method?
I have a helper method which creates an admin "logged
What is the expected behavior when a model has both stub and
should_receive defined for the same method?
I have a helper method which creates an admin "logged in":
def stub_user(is_administrator)
user = stub_model(User)
user.stub(:is_administrator).and_return(is_administrator)
User.
On Thu, Sep 25, 2008 at 1:34 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote:
> On 2008-09-25, at 14:04, David Chelimsky wrote:
>>
>> On Thu, Sep 25, 2008 at 12:47 PM, Nick Hoffman <[EMAIL PROTECTED]>
>> wrote:
>>>
>>> I'm calling #stub! and #should_receive on the same method within a class,
>>> and am
On 2008-09-25, at 14:04, David Chelimsky wrote:
On Thu, Sep 25, 2008 at 12:47 PM, Nick Hoffman <[EMAIL PROTECTED]>
wrote:
I'm calling #stub! and #should_receive on the same method within a
class,
and am finding that the method doesn't return the value given to
#stub!
216 it 'should mak
2008-09-25 14:04, Nick Hoffman:
> I knew there was a dead simple answer to the question. Thanks, Tero.
> Apologies for the brain fart.
Np. Done the same quite a few times myself. ;)
--
Tero Tilus ## 050 3635 235 ## http://www.tilus.net/koti/tero/
___
On Thu, Sep 25, 2008 at 1:04 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote:
> On 2008-09-25, at 13:58, Tero Tilus wrote:
>>
>> 2008-09-25 13:47, Nick Hoffman:
>>>
>>> I'm calling #stub! and #should_receive on the same method within a
>>> class, and am finding that the method doesn't return the value g
On Thu, Sep 25, 2008 at 12:47 PM, Nick Hoffman <[EMAIL PROTECTED]> wrote:
> I'm calling #stub! and #should_receive on the same method within a class,
> and am finding that the method doesn't return the value given to #stub!
>
> 216 it 'should make a map marker' do
> 217 mock_property = mo
On 2008-09-25, at 13:58, Tero Tilus wrote:
2008-09-25 13:47, Nick Hoffman:
I'm calling #stub! and #should_receive on the same method within a
class, and am finding that the method doesn't return the value given
to #stub!
How about GMarker.should_receive(:new).with(foo).and_return
mock_marker
2008-09-25 13:47, Nick Hoffman:
> I'm calling #stub! and #should_receive on the same method within a
> class, and am finding that the method doesn't return the value given
> to #stub!
How about GMarker.should_receive(:new).with(foo).and_return mock_marker
--
Tero Tilus ## 050 3635 235 ## htt
I'm calling #stub! and #should_receive on the same method within a
class, and am finding that the method doesn't return the value given
to #stub!
216 it 'should make a map marker' do
217 mock_property = mock 'property',
218 :address => '400 Bloor Street',
219 :title
10 matches
Mail list logo