[rspec-users] error_on is deprecated?

Pat Maddox pergesu at gmail.com
Fri Mar 2 05:12:59 EST 2007


On 3/1/07, David Chelimsky <dchelimsky at gmail.com> wrote:
> On 3/1/07, Pat Maddox <pergesu at gmail.com> wrote:
> > The docs say
> >
> > DEPRECATED. See Spec::Rails::Expectations
> >
> > model.should_have(:no).errors_on(:attribute)
> > model.should_have(1).error_on(:attribute)
> > model.should_have(3).errors_on(:attribute)
> >
> > However the rdoc for Spec::Rails::Expectations shows the same code.
> > The only difference is that it's "model.should
> > have(1).error_on(:attribute) instead"
>
> That's a big difference ;)

I realize there's a huge difference.  In fact...let it be known that
I've read basically every OOP design book known to man.  I've studied
them in depth.  Despite that, 80% of my understanding of OOP comes
from relatively small discussions from David Chelimsky.


> > So is error_on itself deprecated, or is it just the old should_have?
>
> It's specifically "should_have". It'll work fine if you use "should have".

That's all I was asking.

Pat


More information about the rspec-users mailing list