[rspec-users] specs on private methods
Stefan Magnus Landrø
stefan.landro at gmail.com
Wed Jan 9 08:12:17 EST 2008
Well, I think it all depends on the scenario - but in a lot of cases it
should absolutely be considered a code-smell.
2008/1/9, Kerry Buckley <kerry at kerrybuckley.com>:
> On Jan 9, 2008 10:01 AM, Stefan Magnus Landrø <stefan.landro at gmail.com>
> > I totally agree with you, David!
> > For quite a while I was testing all my methods (even had to declare them
> > protected/package scope in java!), but I realized that I was getting
> into a
> > lot of trouble. Now I've shifted to testing functionality in stead of
> > methods.
> > Now, sometimes you might end up having small methods (typically a result
> > refactoring) that are being used by several clients. In that case you
> > start testing those methods, since they actually represent real business
> > logic.
> I wonder whether that is a smell indicating that the functionality in
> those methods really belongs in its own class?
> rspec-users mailing list
> rspec-users at rubyforge.org
Bekk Open Source
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rspec-users