1IO::Async::LoopTests(3)User Contributed Perl DocumentatioInO::Async::LoopTests(3)
2
3
4
6 "IO::Async::LoopTests" - acceptance testing for "IO::Async::Loop"
7 subclasses
8
10 use IO::Async::LoopTests;
11 run_tests( 'IO::Async::Loop::Shiney', 'io' );
12
14 This module contains a collection of test functions for running
15 acceptance tests on IO::Async::Loop subclasses. It is provided as a
16 facility for authors of such subclasses to ensure that the code
17 conforms to the Loop API required by "IO::Async".
18
20 Certain tests require the use of timers or timed delays. Normally these
21 are counted in units of seconds. By setting the environment variable
22 "TEST_QUICK_TIMERS" to some true value, these timers run 10 times
23 quicker, being measured in units of 0.1 seconds instead. This value may
24 be useful when running the tests interactively, to avoid them taking
25 too long. The slower timers are preferred on automated smoke-testing
26 machines, to help guard against false negatives reported simply because
27 of scheduling delays or high system load while testing.
28
29 TEST_QUICK_TIMERS=1 ./Build test
30
32 run_tests( $class, @tests )
33 Runs a test or collection of tests against the loop subclass given. The
34 class being tested is loaded by this function; the containing script
35 does not need to "require" or "use" it first.
36
37 This function runs "Test::More::plan" to output its expected test
38 count; the containing script should not do this.
39
41 The following test suite names exist, to be passed as a name in the
42 @tests argument to "run_tests":
43
44 io
45 Tests the Loop's ability to watch filehandles for IO readiness
46
47 timer
48 Tests the Loop's ability to handle timer events
49
50 signal
51 Tests the Loop's ability to watch POSIX signals
52
53 idle
54 Tests the Loop's support for idle handlers
55
56 child
57 Tests the Loop's support for watching child processes by PID
58
59 control
60 Tests that the "loop_once" and "loop_forever" methods behave correctly
61
63 Paul Evans <leonerd@leonerd.org.uk>
64
65
66
67perl v5.12.1 2010-06-09 IO::Async::LoopTests(3)