Test-More / TB2

Test::Builder version 2, the next generation of building testing modules in Perl
Other
1 stars 0 forks source link

Put a test_number counter back into History #172

Closed schwernbot closed 10 years ago

schwernbot commented 10 years ago

From: @schwern Date: Wednesday Nov 09, 2011 at 20:50 GMT Orig: https://github.com/Test-More/test-more/issues/190

Now that the test_number is attached to the Result object there's less work for an EventWatcher to do and it's more generically applicable.

Move the counter out of the TAP formatter and into the History object.

History will track the last test_number seen on a result, so others can check if an incoming result is out of order. History's accept_result will set the last number seen to the result's test_number OR increment it if it doesn't have one.

History will also track if it's seen any out of order results and hold onto a list of them.

schwernbot commented 10 years ago

From: @schwern Date: Saturday Mar 31, 2012 at 16:27 GMT Orig: https://github.com/Test-More/test-more/issues/190#issuecomment-4859574

I don't think the History should do any implicit shenanigans about setting the counter to match the result test number. I'd rather that was explicit behavior than try to guess.

History doesn't currently track out of order tests, but I think that's a separate issue.

So this can be closed up.