From: Peter Rabbitson Date: Wed, 2 Oct 2013 23:15:30 +0000 (+0200) Subject: Fail early properly even in the presence of -jN X-Git-Tag: v0.08260~131 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=1439bf153439341cdba3ed1e53141ed5a0575705;p=dbsrgits%2FDBIx-Class.git Fail early properly even in the presence of -jN Without the reordering of prints and without the mysterious sleep() call it seems that prove just loses the STDERR text entirely --- diff --git a/t/lib/DBICTest/RunMode.pm b/t/lib/DBICTest/RunMode.pm index 0b24b95..5b60130 100644 --- a/t/lib/DBICTest/RunMode.pm +++ b/t/lib/DBICTest/RunMode.pm @@ -93,10 +93,8 @@ sub _check_author_makefile { } if (@fail_reasons) { - print STDOUT "\nBail out!\n"; print STDERR <<'EOE'; - !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ======================== FATAL ERROR =========================== !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! @@ -133,6 +131,9 @@ EOE } print STDERR "\n\n\n"; + require Time::HiRes; + Time::HiRes::sleep(0.005); + print STDOUT "\nBail out!\n"; exit 1; } }