[rspec-users] Can I do foo.should (be_nil || be_empty) in rspec
Andrew Premdas
apremdas at gmail.com
Tue Nov 4 06:26:55 EST 2008
Sweet I'm using rails so will give it a go. Any ideas about the general
case, is making a custom matcher the (only) way to go?
All best
Andrew
2008/11/4 Tom Stuart <tom at experthuman.com>
> On 4 Nov 2008, at 11:10, Andrew Premdas wrote:
>
>> Is there any way to do
>> foo.should (be_nil || be_empty)
>> in rspec.
>>
>
> "foo.should be_blank" would work if you're using Rails (i.e. ActiveSupport
> is loaded).
>
> Cheers,
> -Tom
> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20081104/979b8f4e/attachment.html>
More information about the rspec-users
mailing list