[Rspec-devel] [Rspec-users] single specs

aslak hellesoy aslak.hellesoy at gmail.com
Mon Aug 28 03:33:49 EDT 2006

On 8/28/06, David Chelimsky <dchelimsky at gmail.com> wrote:
> The spec command has an option to run a single spec. I'm realizing
> that I never, ever use this. Does anyone else? If not, I'd like to get
> rid of it! It's one of those things that "seemed like a good idea at
> the time", but resulted in a bunch of hack-ish code.

I use this feature a lot. It's especially useful when you have a bunch
of slow specs.
Even as one of the writers of Ashcroft
(http://docs.codehaus.org/display/ASH/Home) slow specs are sometimes

Now for example, I'm writing a library that interfaces with a local
scm, which is inherently slow.

Example of the way I use it is:

1) spec # run all specs - they pass. The suite takes 15 seconds (sloooow)
2) Do a refactoring
3) spec # 10 of the specs fail
4) spec -s 'One of the failing specs' # Takes 1 second instead of 15.

The nice thing about this is that the argument to -s can be copied and
pasted from the error messages.

So please don't remove this feature.


> _______________________________________________
> Rspec-users mailing list
> Rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users

More information about the Rspec-devel mailing list