Re: TAP::Harness timeout?
[email protected] (Ovid) Wed, 29 Jan 2014 08:03:55 -0800 (PST)
| Newsgroups | perl.qa |
|---|---|
| Message-ID | <[email protected]> |
I don't know how easy that is to do with Test::Harness, though my App::Prove::Plugin::ProgressBar[1] might put you in the right direction. Alternatively, Test::Class::Moose[2] has a "reporting" feature that reports on timing and breaks it down into system, real and user time. You should be able to hook into that (or just take advantage of the fact that it's an OO feature and use the normal timeout features with alarm that you would do for regular classes. 1. https://github.com/Ovid/App-Prove-Plugin-ProgressBar 2. http://search.cpan.org/dist/Test-Class-Moose/ Cheers, Ovid -- IT consulting, training, international recruiting http://www.allaroundtheworld.fr/. Buy my book! - http://bit.ly/beginning_perl Live and work overseas - http://www.overseas-exile.com/ On Wednesday, 29 January 2014, 6:50, Todd Rinaldo <[email protected]> wrote: I’m looking at using TAP::Harness to process our test suite. Up to now we’ve been using some home grown code that IMHO is a heroic attempt to re-implement TAP::Harness. > >It seems to do everything we need with one exception. We have rules that disallow a unit test from taking more than XXX seconds to run. If it exceeds that, we abort the test and move on to the next one, declaring the long test file a failure. Before I look at subclassing, can anyone tell me if there’s a way to do this with the existing code? > >Thanks, >Todd > > >