From: David Corbin Date: 2003-09-15T21:15:33+09:00 Subject: Re: Test::Unit -- multiple errors in test method ??? On Monday 15 September 2003 08:08, Johan Holmberg wrote: > Hi ! > > I have been writing some unit tests with Test::Unit. > The two last assertions aren't even executed. > Is this a but or an intentional "feature" ? "feature" > > I've looked at the way JUNIT in Java does the same thing, > and there I got *all* errors reported. That seems much more useful > to mee. You'd better look more closely. JUnit stops execution of the test at the first failed assertion. Of course, it doesn't report how many assertions it's making, so maybe it's less obvious to you. > > With the current Test::Unit behaviour in Ruby, I can't know if > an error "hides" a number of other errors until I've fixed the first > error (it feels like having a C-compiler that only report the first > compilation error ...). > If you've got a number of assertions in one test case, while not always, often they are "ascendent". That is, the second asssertion can only really be checked. if the first one is true. For example, so people might right assert_not_nil(a) assert_equals("foo",a.name) > > /Johan Holmberg -- David Corbin