On 20 Mar 2008, at 14:31, Max Williams wrote:

> Sorry to be pedantic, but shouldn't that be
> "Your needs may differ from mine"?  There's no party called 'mine', so
> 'mine' has no needs :)

A quick google for "those of mine" brings back a google book hit for  
Shakespeare so maybe Edvard was being poetic :D


> Anyway, does anyone have any idea why
> -e "the name of a describe block"
>
> results in 0 tests being run for me?

Are you sure you are running the outer-most group, and not an inner  
group or example?  I just tried this file as test.spec.rb:
   describe "add_descendants_from_xml" do
     it "should add descendants" do
       true.should be_false
     end

     describe "with attributes" do
       it "should add attributes too" do
         false.should be_true
       end
     end
   end

* the outer group name works

~/Desktop % spec -e "add_descendants_from_xml" test.spec.rb
F
1)
'add_descendants_from_xml should add descendants' FAILED
expected false, got true
./test.spec.rb:3:
Finished in 0.007168 seconds

* testing the name of the inner group fails

~/Desktop % spec -e "with attributes" test.spec.rb
Finished in 0.001734 seconds
0 examples, 0 failures

* but, as expected

~/Desktop % spec -e "add_descendants_from_xml with attributes"  
test.spec.rb
F
1)
'add_descendants_from_xml with attributes should add attributes too'  
FAILED
expected true, got false
./test.spec.rb:8:
Finished in 0.007056 seconds

Failing that, are you sure you haven't got a typo?  I can't see a  
problem with the -e option.

Ashley
_______________________________________________
rspec-users mailing list
rspec-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/rspec-users

Reply via email to