[rspec-users] Problem verifying routing error
r_j_h_box-sf at yahoo.com
Mon May 11 00:33:32 EDT 2009
>> NoMethodError in 'ItemsController route generation should NOT map
>> You have a nil object when you didn't expect it!
>> You might have expected an instance of Array.
>> The error occurred while evaluating nil.first
[reordered] Ben Mabey:
> Hmm.. yeah, it seems like it might have to do with how the exceptions
> are being handled in the newer version of rspec-rials (see
Right, the bypass_rescue() method. Just to clarify:
>> I tried using bypass_rescue in my routing/items_routing_spec.rb file as
>> mentioned by the upgrade doc, but it wasn't valid in the "routing" spec
>> - worked fine when I moved the file back to spec/controllers/, though.
"worked fine", by which I mean "didn't have a problem with me calling
it" - but didn't provide any exception for me to catch.
> I don't use RSpec to verify my routes very often and have never used it
> to verify the non-existence of a route so I'm afraid I don't really have
> any ideas...
Maybe I'm out of my tree a bit to want it. I guess I don't really care
to validate has_many relationships, why should it matter to validate
:except rules? Should I adjust my thinking on this one?
More information about the rspec-users