Rspec-2.2 is released!

rspec-core-2.2.0

full
changelog

  • Deprecations/changes

    • –debug/-d on command line is deprecated and now has no effect
    • win32console is now ignored; Windows users must use ANSICON for
      color support
      (Bosko I.)
  • Enhancements

    • Raise exception with helpful message when rspec-1 is loaded
      alongside
      rspec-2 (Justin Ko)
    • debugger statements just work as long as ruby-debug is installed
      • otherwise you get warned, but not fired
    • Expose example.metadata in around hooks
    • Performance improvments (see
      Upgrade.markdown)
  • Bug fixes

    • Make sure --fail-fast makes it across drb
    • Pass -Ilib:spec to rcov

rspec-mocks-2.2.0

full
changelog

  • Enhancements

    • Added “rspec/mocks/standalone” for exploring the rspec-mocks in irb.
  • Bug fix

    • Eliminate warning on splat args without parens (Gioele B.)
    • Fix bug where obj.should_receive(:foo).with(stub.as_null_object)
      would
      pass with a false positive.

rspec-rails-2.2.0

full
changelog

  • Enhancements

    • Added stub_template in view specs
  • Bug fixes

    • Properly include helpers in views (Jonathan del Strother)
    • Fix bug in which method missing led to a stack overflow
    • Fix stack overflow in request specs with open_session
    • Fix stack overflow in any spec when method_missing was invoked
    • Add gem dependency on rails ~> 3.0.0 (ensures bundler won’t install
      rspec-rails-2 with rails-2 apps).

David C. wrote:

  • debugger statements just work as long as ruby-debug is installed
    • otherwise you get warned, but not fired

Great news David, but I have a question.

I’ve always found that when stopping at a debugger statement,
the debugger’s “where” statement shows no stack trace. This
is because the debugger didn’t installed its hook until it
was called, which is too late. The work-around I found was
to call Debugger.start somewhere in global scope, but after
ruby-debug had been required.

The workaround is painful, and I was considering asking that
the “-d”/"–debugger" option should do it… not possible now
that you’ve removed the option!

Is there any way to get the initial stack trace to work correctly?
Perhaps add “-d” again to support this case?

Clifford H…

David, it’s been a while since I said Thank You, so I just want to say
Thank You for everything you do for rspec.
:slight_smile:

–linoj

On Nov 28, 2010, at 5:35 PM, David C. wrote:

  • Raise exception with helpful message when rspec-1 is loaded alongside

rspec-mocks-2.2.0

  • Fix stack overflow in request specs with open_session
  • Fix stack overflow in any spec when method_missing was invoked
  • Add gem dependency on rails ~> 3.0.0 (ensures bundler won’t install
    rspec-rails-2 with rails-2 apps).

rspec-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/rspec-users

– jonathan linowes
parkerhill technology group llc
[email protected]
office: 603-838-2884

tech blog: http://vaporbase.com
personal tumblog: http://jon.linow.es
facebook: http://facebook.com/jon.linowes
twitter: @linojon

On Nov 28, 2010, at 4:35 PM, David C. wrote:

rspec-core-2.2.0

Wow, the perf improvements are much appreciated!

My test suite (MRI 1.9.2p0) with 3300 examples went from 7.4s under
2.1.0 to 3.2s with 2.2.1. Most excellent!

cr

On Nov 28, 2010, at 14:36 , David C. wrote:

from the Upgrade page:

Made several small optimizations that all add up to a considerable improvement
in performance. Using a simple benchmark:

generate 5000 example groups,
each with one example,
each with one passing expectation

Unfortunately, this isn’t enough of a benchmark. You really should to
generate both the positive and negative cases as error handling often
incurs a lot of extra overhead.

You can see my numbers for positive and negative (against rspec 2.0 and
1.x, and a bunch of other test frameworks) here:

Test Framework Benchmark (iter = 1000)

On Nov 29, 2010, at 8:04 AM, Chuck R. wrote:

My test suite (MRI 1.9.2p0) with 3300 examples went from 7.4s under 2.1.0 to
3.2s with 2.2.1. Most excellent!
Glad to hear it. My benchmarks were based on an essentially empty spec
suite (so no overhead from the implementation code). Hearing that with a
real app we’re still getting 1k examples per second makes me very happy
:slight_smile: I’m assuming, however, this is not a Rails app, correct?

On Nov 29, 2010, at 9:27 AM, David C. wrote:

Wow, the perf improvements are much appreciated!

My test suite (MRI 1.9.2p0) with 3300 examples went from 7.4s under 2.1.0 to
3.2s with 2.2.1. Most excellent!

Glad to hear it. My benchmarks were based on an essentially empty spec suite (so
no overhead from the implementation code). Hearing that with a real app we’re
still getting 1k examples per second makes me very happy :slight_smile: I’m assuming, however,
this is not a Rails app, correct?

Correct, this is not a rails app. I write straight-up ruby code. :slight_smile:

cr