Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: Timeout on prove

by tobyink (Canon)
on Jul 02, 2014 at 19:24 UTC ( [id://1092037]=note: print w/replies, xml ) Need Help??


in reply to Timeout on prove

Install Time::Limit and then run:

prove -MTime::Limit=60 -Ilib /path/to/tests

(This works less well if you are using forkprove, but should be fine with the standard prove tool.)

Or in an individual test:

use Time::Limit "30"; # quote marks around the number are required!

Update: actually it works OK with forkprove, if you get Time::Limit to send its kill signal to the process group:

forkprove -MTime::Limit=-group,60 -Ilib /path/to/tests

Replies are listed 'Best First'.
Re^2: Timeout on prove
by chrestomanci (Priest) on Jul 03, 2014 at 10:56 UTC

    Thanks, that is just what I need.

    I will add an overall time-out of half an hour or so to the overall prove run, and then encourage other developers to add a more conservative time-out to each unit test, so that it times out more quickly if there is a bug.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1092037]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (6)
As of 2024-03-28 14:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found