Re: Role of stories vs specs, revisited

If you were to rename deposit to credit, and withdraw to debit

I’m more concerned with adding a parameter or changing the default value
of a parameter. My fear is that given enough time and size there will be
a fair number of inconsistent mocks or mocks that aren’t doing any real
testing. It feels a bit like forced exception handling in java.

User stories represent some facet of behavior which, once completed,
provides value to the customer. In short, working software. By
definition, then, stories must use real production implementations of
objects instead of mocks. This means they work quite nicely as
integration tests as well.

Does anyone know of any open source ruby apps (preferably rails) that
use good BDD so I can see how it’s done right rather than ask a bunch of
questions?

  ____________________________________________________________________________________

Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now.
http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ

Jay D. wrote:

Does anyone know of any open source ruby apps (preferably rails) that use good BDD so I can see how it’s done right rather than ask a bunch of questions?

Hmm… I don’t know of any rails apps that are open source that you could
look at… But I know datamapper (http://www.datamapper.org/) is using
rspec. Also, be sure to look at rspec’s code if you haven’t already. I
have learned a great deal by looking over its use of itself. :slight_smile:

-Ben

On Jan 12, 2008, at 3:33 PM, Ben M. wrote:

Hmm… I don’t know of any rails apps that are open source that you
could
look at… But I know datamapper (http://www.datamapper.org/) is using
rspec. Also, be sure to look at rspec’s code if you haven’t
already. I
have learned a great deal by looking over its use of itself. :slight_smile:

Yep. Merb, too, as well as Rubinius, which uses “mspec” - a scaled
down version of rspec. Plus - the specs should be pretty easy to
understand, being that they are of ruby itself.

I know Rick O. has started using rspec - you might want to look at
his plugins. I also have a few projects out there using rspec:
DatedBackup, and FixtureReplacement, both on rubyforge.

Hope that helps,

Scott

http://synthesis.rubyforge.org/ just showed up in my feedreader
(well, the links at the bottom did)

On Jan 11, 2008 9:28 PM, Jay D. [email protected] wrote:

If you were to rename deposit to credit, and withdraw to debit

I’m more concerned with adding a parameter or changing the default value of a parameter. My fear is that given enough time and size there will be a fair number of inconsistent mocks or mocks that aren’t doing any real testing. It feels a bit like forced exception handling in java.

Yeah. I played with Synthesis a bit, and it doesn’t handle this case.
It’s very early on though.

I’m not sure that you’ll end up with a number of inconsistent
mocks…because if you have integration tests covering everything,
then you’ll know pretty quickly when your tests aren’t up to par. But
it’s not like you’d have a bunch of passing tests and broken
production code, and deploy that out. Using mocks without acceptance
tests is like using Ruby without any tests. It’s just stupid.

Does anyone know of any open source ruby apps (preferably rails) that use good BDD so I can see how it’s done right rather than ask a bunch of questions?

Not really. Rick Olsen has a Rails example app that uses specs.
There are a bunch of published plugins that use specs.

I’m working on a bliki thing in my spare time (which means never)
which will be open source.

Pat