Skip to content

Commit

Permalink
Added a timeout to the exception test to (hopefully) fail test on bro…
Browse files Browse the repository at this point in the history
…ken perl instead of waiting forever.
  • Loading branch information
lordofhyphens committed Mar 11, 2017
1 parent 6ed98e1 commit 5d10d4c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions xs/t/22_exception.t
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@ use Test::More tests => 1;

{
eval {
local $SIG{ALRM} = sub { die "Timed out waiting for exception\n" }; # NB: \n required
alarm 30;
Slic3r::xspp_test_croak_hangs_on_strawberry();
alarm 0;
};
is $@, "xspp_test_croak_hangs_on_strawberry: exception catched\n", 'croak from inside a C++ exception delivered';
}
Expand Down

0 comments on commit 5d10d4c

Please sign in to comment.