[rspec-users] Outside-In with RSpec on Rails

Marcus Ahnve marcus at ahnve.com
Tue Jul 10 04:22:00 EDT 2007


Whether or not to start with the view is a topic of great debate. Many
agile luminaries propose waiting with the ui for as long as possible,
whereas 37Signals for example won't start coding without a full HTML
mockup.

I've tried all different ways - even starting with the model - but I
agree with David, starting with the view seem to result in less
refactoring.

Cheers /Marcus

On 7/6/07, Jed Hurt <jed.hurt at gmail.com> wrote:
> Cool. I'll have to give it a try on my next project.
>
> On 7/6/07, David Chelimsky <dchelimsky at gmail.com> wrote:
> > On 7/6/07, Jed Hurt <jed.hurt at gmail.com> wrote:
> > > I just read 'Mocks Aren't Stubs' and was intrigued by the notion of
> > > 'outside-in' TDD.
> > >
> > > As a Rails developer, I'm curious if others are employing this method
> > > when developing Rails applications using RSpec. Is it common practice
> > > (or even practical) to drive the development of a Rails app by
> > > starting with view specs, then controller specs, then models?
> >
> > Common? Not from what I've seen. I think that most ppl seem to start
> > w/ the controller.
> >
> > That said, I've been starting with the views with some success. I find
> > that when I've started with the controller, I've ended up doing a lot
> > more refactoring once that slice was done (i.e. a given
> > view/controller action/model trio) than I do when I start w/ the view.
> > In other words, the designs that emerge when I start w/ views are
> > closer to the designs that I want.
> >
> > This is just me. I'm not advocating that this will work for everybody.
> >
> > David
> >
> >
> > > _______________________________________________
> > > rspec-users mailing list
> > > rspec-users at rubyforge.org
> > > http://rubyforge.org/mailman/listinfo/rspec-users
> > >
> > _______________________________________________
> > rspec-users mailing list
> > rspec-users at rubyforge.org
> > http://rubyforge.org/mailman/listinfo/rspec-users
> >
> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users
>


-- 
http://marcus.ahnve.net


More information about the rspec-users mailing list