On Nov 18, 2007 10:10 AM, Jonathan Linowes <[EMAIL PROTECTED]> wrote:
> personally I find this to be one of the most frustrating things about
> rspec, well, rspec's stubs
> and wish the error messages could be much more helpful,
> rather than just telling that an expected method was not called, tel
personally I find this to be one of the most frustrating things about
rspec, well, rspec's stubs
and wish the error messages could be much more helpful,
rather than just telling that an expected method was not called, tell
me if/when it was called with some other args instead
(if this causes ex
On Nov 18, 2007, at 12:04 AM, Chris Olsen wrote:
> Steve Ross wrote:
>> Try with(nil)
>>
>> I think params[:user] will return nil.
>
> yip that works, after fooling with it I also found that :any_args
> works
> as well as any (I guess this one is more than just a symbol)
>
> Thanks for the help
Steve Ross wrote:
> Try with(nil)
>
> I think params[:user] will return nil.
yip that works, after fooling with it I also found that :any_args works
as well as any (I guess this one is more than just a symbol)
Thanks for the help.
--
Posted via http://www.ruby-forum.com/.
Try with(nil)
I think params[:user] will return nil.
On Nov 17, 2007, at 8:18 PM, __iso __ wrote:
>>> Address.should_receive(:new).with(no_args).and_return @address
>
> That doesn't seem to work either. I had also tried with :any and that
> failed as well.
>
> It does seem to work when removin
>> Address.should_receive(:new).with(no_args).and_return @address
That doesn't seem to work either. I had also tried with :any and that
failed as well.
It does seem to work when removing the .with() call though.
--
Posted via http://www.ruby-forum.com/.
___
On Nov 17, 2007, at 10:52 PM, Chris Olsen wrote:
> I am not sure why the tests don't see the call of the new method
> for the
> Address class. It can be seen in the controller method where the
> Address.new is called.
>>> @address = Address.new(params[:address])
>
> What am I doing wrong?
>
Y
I am not sure why the tests don't see the call of the new method for the
Address class. It can be seen in the controller method where the
Address.new is called.
>> @address = Address.new(params[:address])
What am I doing wrong?
Thanks for the help.
Here is the error message:
Spec::Mocks::MockEx