On 10/10/06, Jeff Fry <[EMAIL PROTECTED]> wrote:
def test_random_stuff
1.upto(100) do |stuff|
begin
#each test is somewhat randomized
assert_no_match(certain error)
puts "passed"
rescue => e
puts "error: " + e.to_s
end #begin
end #do
end #test_random_stuff
Hi,
I am trying to do something like:
def test_random_stuff
1.upto(100) do |stuff|
#each test is somewhat randomized
assert_no_match(certain error)
end #do
end #test_random_stuff
current behavior:
test/unit exits the test case as soon as an assertion fails.
what I'd like to end up with is a test that passes or fails and then runs again either way.
It might generate a list of pass/fail results from my random tests, something like:
dataset 1 pass
dataset 2 pass
dataset 3 fail
dataset 4 pass
dataset 5 fail
...
dataset 100 pass
How would you suggest going about this?
Thanks,
Jeff
def test_random_stuff
1.upto(100) do |stuff|
begin
#each test is somewhat randomized
assert_no_match(certain error)
puts "passed"
rescue => e
puts "error: " + e.to_s
end #begin
end #do
end #test_random_stuff
_______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
