Philip Hallstrom wrote:

> You've overridden it so I doubt this is the problem, but display is a
> built-in method at a very basic level (somewhere near inspect) so
> maybe that's messing you up in case you aren't overriding it correctly.
> 

I changed the method name to display_field, but the test still fails.



> Are you sure you didn't mean ["purpose LIKE ?", purpose]  There's no
> reason to quote the second argument.  Although I don't know what Rails
> does when you pass in nil to conditions like that.  Maybe it doesn't
> like that.
> 


I modified this also and the test passes/fails both ways.


>  >> nil.to_s
> => ""
> 
> So, something else is wrong somewhere...


Tests run on this method work fine if I'm not passing in a nil value. 
I'm not quite sure where else to look.  Any thoughts?

Thanks.
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to