This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
blame
|
history
|
raw
|
HEAD
Test for +x bits for all the files in exec-bit.txt
[perl5.git]
/
t
/
op
/
sigdispatch.t
1
#!perl -w
2
3
# We assume that TestInit has been used.
4
5
BEGIN {
6
require './test.pl';
7
}
8
9
use strict;
10
11
plan tests => 4;
12
13
watchdog(10);
14
15
$SIG{ALRM} = sub {
16
die "Alarm!\n";
17
};
18
19
pass('before the first loop');
20
21
alarm 2;
22
23
eval {
24
1 while 1;
25
};
26
27
is($@, "Alarm!\n", 'after the first loop');
28
29
pass('before the second loop');
30
31
alarm 2;
32
33
eval {
34
while (1) {
35
}
36
};
37
38
is($@, "Alarm!\n", 'after the second loop');