[Rspec-devel] -s not working

David Chelimsky dchelimsky at gmail.com
Sat May 20 01:10:25 EDT 2006


I've committed changes to svn to support these formats:

"context"
"context spec"
"spec"

Still need to add the following:
- message when no specs are found to match
- documentation

Cheers,
David

On 5/16/06, David Chelimsky <dchelimsky at gmail.com> wrote:
> On 5/16/06, aslak hellesoy <aslak.hellesoy at gmail.com> wrote:
> > On 5/16/06, David Chelimsky <dchelimsky at gmail.com> wrote:
> > >
> > > etc. Other options would be to accept any of the following:
> > >
> > > "context"
> > > "context - spec"
> > > "spec"
> > >
> > > then let rspec run whatever it finds that it think matches.
> > >
> >
> > i think rspec should try to be smart, have a simple ui and give
> > intelligent feedback when it can't do anything. in more formal (bdd
> > story format) words: (as a [role] i want a [feature] so that
> > [benefit])
> >
> >
> > as a rspec user
> > i want a single option to filter out what context and/or
> > specifications i want to run.
> > so that i don't have to read the docs when i want to run a subset of my specs.
> >
> > acceptance criteria:
> >
> > given:
> >
> > context 'foo' do
> >   specify 'bar' do
> >   end
> > end
> >
> > context 'mooky' do
> >   specify 'bar' do
> >   end
> > end
> >
> > when:
> > spec -s bar
> >
> > then:
> > rspec runs 'foo bar' and 'mooky bar'
> >
> > when:
> > spec -s 'foo bar'
> >
> > then:
> > rspec runs 'foo bar'
> >
> > when:
> > spec -s 'foo'
> >
> > then:
> > rspec runs 'foo bar'
> >
> > when:
> > spec -s cow
> >
> > then:
> > rspec tells me there was no context or spec with the name 'cow'
> >
> >
> > wdyt?
>
> That's what I had in mind w/ the suggestion above. I'll set it up.
>


More information about the Rspec-devel mailing list