File: unconfigured.t

package info (click to toggle)
libevent-perl 1.28-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 776 kB
  • sloc: ansic: 3,035; perl: 1,122; makefile: 8
file content (27 lines) | stat: -rw-r--r-- 446 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!./perl -w

use strict;
use Test; plan test => 6;
use Event;

my @p = (cb=>\&die);

eval { Event->io(@p) };
ok $@, '/unconfigured/';

eval { Event->signal(@p) };
ok $@, '/without signal/';

eval { Event->timer(@p) };
ok $@, '/unset/';

eval { Event->var(@p) };
ok $@, '/watching what/';

my $var = 1;

eval { Event->var(@p, poll => 0, var => \$var) };
ok $@, '/without poll events/';

eval { Event->var(@p, var => \$]) };
ok $@, '/read\-only/';