[Rspec-devel] -s not working

David Chelimsky dchelimsky at gmail.com
Tue May 16 22:04:00 EDT 2006


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