Nested describe blocks

In 1.0.8 I am able to nest describe blocks, but in moving to trunk,
revision 2971, I am unable to have the expected results. Here is an
example nested describe block:

describe “foo” do
describe “with no arguments” do
before do
puts “a”
end

it "should" do
  puts "SHOULD"
end

end

describe “with invalid arguments” do
before do
puts “b”
end

it "shouldn't" do
  puts "SHOULDN'T"
end

end
end

Here is the output in trunk (revision 2971):

a
b
SHOULD
a
b
SHOULDN’T

Here is the output with 1.0.8:

a
SHOULD
b
SHOULDN’T

The 1.0.8 output is what I expect. I don’t believe this is a feature
of rspec in the first place, just an not-so-ordinary way to organize
some specs. Any chance of having this work as I expect?

Zach

On 10/4/07, Zach D. [email protected] wrote:

it "should" do
  puts "SHOULDN'T"

b
of rspec in the first place, just an not-so-ordinary way to organize
some specs. Any chance of having this work as I expect?

We’ve had years of discussions about this (google for “rspec nested
contexts”). In short, not much chance. The fact that it worked before
was pure luck and never intended. Sorry man.

Ah, I was using the wrong search term. Thanks for the fast response,

Zach