Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Make the tests generally ASSERT_DEFAULT clean. POE_TRACE_FILENAME hid…

… a multitude of sins in the test output file. Update the vim options lines while I'm in there.
  • Loading branch information...
commit c196b75f5a440d19b5730a78928ffacfe0d5239a 1 parent 590b276
Rocco Caputo authored

Showing 63 changed files with 198 additions and 64 deletions. Show diff stats Hide diff stats

  1. +3 1 t/00_info.t
  2. +1 1  t/10_units/01_pod/01_pod.t
  3. +1 1  t/10_units/01_pod/02_pod_coverage.t
  4. +1 0  t/10_units/02_pipes/01_base.t
  5. +1 0  t/10_units/02_pipes/02_oneway.t
  6. +1 0  t/10_units/02_pipes/03_twoway.t
  7. +1 1  t/10_units/03_base/03_component.t
  8. +1 0  t/10_units/03_base/04_driver.t
  9. +1 0  t/10_units/03_base/05_filter.t
  10. +1 1  t/10_units/03_base/06_loop.t
  11. +1 0  t/10_units/03_base/07_queue.t
  12. +1 1  t/10_units/03_base/08_resource.t
  13. +1 0  t/10_units/03_base/09_resources.t
  14. +1 0  t/10_units/03_base/10_wheel.t
  15. +6 3 t/10_units/03_base/11_assert_usage.t
  16. +5 1 t/10_units/03_base/12_assert_retval.t
  17. +5 1 t/10_units/03_base/13_assert_data.t
  18. +1 0  t/10_units/03_base/14_kernel.t
  19. +6 0 t/10_units/03_base/16_explicit_loop.t
  20. +6 0 t/10_units/03_base/17_explicit_loop_fail.t
  21. +1 0  t/10_units/03_base/18_nfa_usage.t
  22. +1 1  t/10_units/04_drivers/01_sysrw.t
  23. +6 3 t/10_units/05_filters/01_block.t
  24. +2 0  t/10_units/05_filters/02_grep.t
  25. +1 0  t/10_units/05_filters/03_http.t
  26. +6 3 t/10_units/05_filters/04_line.t
  27. +2 0  t/10_units/05_filters/05_map.t
  28. +1 0  t/10_units/05_filters/06_recordblock.t
  29. +6 3 t/10_units/05_filters/07_reference.t
  30. +6 2 t/10_units/05_filters/08_stream.t
  31. +6 3 t/10_units/05_filters/50_stackable.t
  32. +6 3 t/10_units/05_filters/99_filterchange.t
  33. +6 2 t/10_units/06_queues/01_array.t
  34. +1 1  t/10_units/07_exceptions/01_normal.t
  35. +2 1  t/10_units/07_exceptions/02_turn_off.t
  36. +1 0  t/10_units/07_exceptions/03_not_handled.t
  37. +2 0  t/20_resources/00_base/caller_state.pm
  38. +3 1 t/20_resources/00_base/extrefs_gc.pm
  39. +6 2 t/20_resources/00_base/filehandles.pm
  40. +6 2 t/20_resources/00_base/sessions.pm
  41. +6 2 t/20_resources/00_base/sids.pm
  42. +6 2 t/20_resources/00_base/signals.pm
  43. +1 1  t/90_regression/agaran-filter-httpd.t
  44. +6 0 t/90_regression/averell-callback-ret.t
  45. +1 1  t/90_regression/bingos-followtail.t
  46. +1 1  t/90_regression/broeren-win32-nbio.t
  47. +1 1  t/90_regression/cfedde-filter-httpd.t
  48. +1 0  t/90_regression/ferrari-server-unix.t
  49. +3 2 t/90_regression/kjeldahl-stop-start-polling.t
  50. +3 2 t/90_regression/kjeldahl-stop-start-sig-nopipe.t
  51. +3 2 t/90_regression/kjeldahl-stop-start-sig-pipe.t
  52. +7 0 t/90_regression/neyuki_detach.t
  53. +1 1  t/90_regression/rt14444-arg1.t
  54. +7 1 t/90_regression/rt1648-tied-stderr.t
  55. +1 1  t/90_regression/rt19908-merlyn-stop.t
  56. +7 1 t/90_regression/rt23181-sigchld-rc.t
  57. +1 1  t/90_regression/rt47966-sigchld.t
  58. +1 0  t/90_regression/somni-poco-server-tcp.t
  59. +6 3 t/90_regression/steinert-passed-wheel.t
  60. +6 3 t/90_regression/suzman_windows.t
  61. +6 0 t/90_regression/ton-stop-corruption.t
  62. +6 0 t/90_regression/whelan-dieprop.t
  63. +1 1  t/90_regression/whjackson-followtail.t
4 t/00_info.t
... ... @@ -1,5 +1,7 @@
1 1 #!/usr/bin/perl
2   -use strict; use warnings;
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
  3 +use warnings;
  4 +use strict;
3 5
4 6 use Test::More tests => 1;
5 7 use_ok( 'POE' );
2  t/10_units/01_pod/01_pod.t
... ... @@ -1,4 +1,4 @@
1   -# vim: filetype=perl
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
2 2
3 3 use Test::More;
4 4 eval "use Test::Pod 1.00";
2  t/10_units/01_pod/02_pod_coverage.t
... ... @@ -1,4 +1,4 @@
1   -# vim: filetype=perl
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
2 2
3 3 # This testcase loads all POE modules. Some of them may define
4 4 # alternative methods with the same full-qualified names. Disable the
1  t/10_units/02_pipes/01_base.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
1  t/10_units/02_pipes/02_oneway.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
1  t/10_units/02_pipes/03_twoway.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
2  t/10_units/03_base/03_component.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
1  t/10_units/03_base/04_driver.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
1  t/10_units/03_base/05_filter.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
2  t/10_units/03_base/06_loop.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
1  t/10_units/03_base/07_queue.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
2  t/10_units/03_base/08_resource.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
1  t/10_units/03_base/09_resources.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
1  t/10_units/03_base/10_wheel.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
9 t/10_units/03_base/11_assert_usage.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Test the ASSERT_USAGE code in POE::Kernel. This involves a lot of
5 5 # dying.
@@ -12,8 +12,11 @@ use Test::More tests => 76;
12 12 use Symbol qw(gensym);
13 13
14 14 sub POE::Kernel::ASSERT_USAGE () { 1 }
15   -sub POE::Kernel::TRACE_REFCNT () { 1 }
16   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  15 +#sub POE::Kernel::TRACE_REFCNT () { 1 }
  16 +BEGIN {
  17 + package POE::Kernel;
  18 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  19 +}
17 20
18 21 BEGIN { use_ok("POE") }
19 22
6 t/10_units/03_base/12_assert_retval.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Test the ASSERT_USAGE code in POE::Kernel. This involves a lot of
4 5 # dying.
@@ -9,7 +10,10 @@ use lib qw(./mylib);
9 10 use Test::More tests => 22;
10 11
11 12 sub POE::Kernel::ASSERT_RETVALS () { 1 }
12   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  13 +BEGIN {
  14 + package POE::Kernel;
  15 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  16 +}
13 17
14 18 BEGIN { use_ok("POE") }
15 19
6 t/10_units/03_base/13_assert_data.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Test the ASSERT_DATA code in POE::Kernel. This involves a lot of
4 5 # dying.
@@ -12,7 +13,10 @@ use lib qw(./mylib);
12 13 use Test::More tests => 7;
13 14
14 15 sub POE::Kernel::ASSERT_DATA () { 1 }
15   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  16 +BEGIN {
  17 + package POE::Kernel;
  18 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  19 +}
16 20
17 21 BEGIN { use_ok("POE") }
18 22
1  t/10_units/03_base/14_kernel.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # This file contains tests for the _public_ POE::Kernel interface
4 5
6 t/10_units/03_base/16_explicit_loop.t
... ... @@ -1,7 +1,13 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
5 6 use Test::More tests => 1;
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  8 +
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
7 13 BEGIN { use_ok("POE", "Loop::Select") }
6 t/10_units/03_base/17_explicit_loop_fail.t
... ... @@ -1,10 +1,16 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
5 6 use Test::More tests => 1;
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
7 8
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
  13 +
8 14 # Hide warnings.
9 15 {
10 16 local $SIG{__WARN__} = sub { undef };
1  t/10_units/03_base/18_nfa_usage.t
... ... @@ -1,4 +1,5 @@
1 1 use strict;
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 package main;
4 5
2  t/10_units/04_drivers/01_sysrw.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
9 t/10_units/05_filters/01_block.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Exercises Filter::Block without the rest of POE. Suddenly things
5 5 # are looking a lot easier.
@@ -12,8 +12,11 @@ use TestFilter;
12 12 use Test::More tests => 20 + $COUNT_FILTER_INTERFACE;
13 13
14 14 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
15   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
16   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  15 +
  16 +BEGIN {
  17 + package POE::Kernel;
  18 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  19 +}
17 20
18 21 use_ok("POE::Filter::Block");
19 22 test_filter_interface("POE::Filter::Block");
2  t/10_units/05_filters/02_grep.t
... ... @@ -1,4 +1,6 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
  3 +
2 4 # Exercises Filter::Grep without POE
3 5
4 6 use strict;
1  t/10_units/05_filters/03_http.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Test Filter::HTTPD by itself
4 5 # See other (forthcoming) for more complex interactions
9 t/10_units/05_filters/04_line.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Exercises Filter::Line without the rest of POE.
5 5
@@ -8,8 +8,11 @@ use lib qw(./mylib ../mylib);
8 8 use lib qw(t/10_units/05_filters);
9 9
10 10 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
11   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
12   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  11 +
  12 +BEGIN {
  13 + package POE::Kernel;
  14 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  15 +}
13 16
14 17 use TestFilter;
15 18 use Test::More tests => 18 + $COUNT_FILTER_INTERFACE + 2*$COUNT_FILTER_STANDARD;
2  t/10_units/05_filters/05_map.t
... ... @@ -1,4 +1,6 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
  3 +
2 4 # Exercises Filter::Map without POE
3 5
4 6 use strict;
1  t/10_units/05_filters/06_recordblock.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Exercises POE::Filter::RecordBlock without the rest of POE
4 5
9 t/10_units/05_filters/07_reference.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Exercises Filter::Reference without the rest of POE.
5 5
@@ -8,8 +8,11 @@ use lib qw(./mylib ../mylib);
8 8 use lib qw(t/10_units/05_filters);
9 9
10 10 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
11   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
12   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  11 +
  12 +BEGIN {
  13 + package POE::Kernel;
  14 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  15 +}
13 16
14 17 use TestFilter;
15 18 use Test::More;
8 t/10_units/05_filters/08_stream.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Exercises Filter::Stream without the rest of POE.
4 5
@@ -10,8 +11,11 @@ use TestFilter;
10 11 use Test::More tests => 9 + $COUNT_FILTER_INTERFACE + $COUNT_FILTER_STANDARD;
11 12
12 13 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
13   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
14   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  14 +
  15 +BEGIN {
  16 + package POE::Kernel;
  17 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  18 +}
15 19
16 20 use_ok("POE::Filter::Stream");
17 21 test_filter_interface("POE::Filter::Stream");
9 t/10_units/05_filters/50_stackable.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Exercises Filter::Stack (and friends) without the rest of POE.
5 5
@@ -7,8 +7,11 @@ use strict;
7 7 use lib qw(./mylib ../mylib);
8 8
9 9 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
10   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
11   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  10 +
  11 +BEGIN {
  12 + package POE::Kernel;
  13 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  14 +}
12 15
13 16 use Test::More tests => 29;
14 17
9 t/10_units/05_filters/99_filterchange.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Exercises filter changing. A lot of this code comes from Philip
5 5 # Gwyn's filterchange.perl sample.
@@ -13,8 +13,11 @@ use MyOtherFreezer;
13 13 sub DEBUG () { 0 }
14 14
15 15 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
16   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
17   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  16 +
  17 +BEGIN {
  18 + package POE::Kernel;
  19 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  20 +}
18 21
19 22 use POE qw(
20 23 Wheel::ReadWrite Driver::SysRW
8 t/10_units/06_queues/01_array.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Tests basic queue operations.
4 5
@@ -9,8 +10,11 @@ use lib qw(./mylib);
9 10 use Test::More tests => 2047;
10 11
11 12 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
12   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
13   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  13 +
  14 +BEGIN {
  15 + package POE::Kernel;
  16 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  17 +}
14 18
15 19 use POSIX qw(EPERM ESRCH);
16 20
2  t/10_units/07_exceptions/01_normal.t
... ... @@ -1,4 +1,4 @@
1   -# vim: filetype=perl
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
2 2
3 3 use Test::More tests => 7;
4 4
3  t/10_units/07_exceptions/02_turn_off.t
... ... @@ -1,6 +1,7 @@
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
1 2 use Test::More tests => 3;
2 3
3   -BEGIN { sub POE::Kernel::CATCH_EXCEPTIONS () { 0 } }
  4 +sub POE::Kernel::CATCH_EXCEPTIONS () { 0 }
4 5 use POE;
5 6
6 7 eval {
1  t/10_units/07_exceptions/03_not_handled.t
... ... @@ -1,3 +1,4 @@
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
1 2 use Test::More tests => 7;
2 3
3 4 use POE;
2  t/20_resources/00_base/caller_state.pm
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 expandtab
2 3
3 4 # Test that caller_state returnes expected results
4 5
@@ -8,6 +9,7 @@ use lib qw(./mylib ../mylib);
8 9 use Test::More tests => 6;
9 10
10 11 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  12 +sub POE::Kernel::TRACE_DEFAULT () { 0 }
11 13
12 14 BEGIN { use_ok("POE") } # 1
13 15
4 t/20_resources/00_base/extrefs_gc.pm
... ... @@ -1,4 +1,4 @@
1   -# vim: filetype=perl
  1 +# vim: ts=2 sw=2 expandtab
2 2
3 3 # Test a case that Yuval Kogman ran into. Decrementing a reference
4 4 # count would immediately trigger a GC test. During _start, that
@@ -11,6 +11,8 @@ use strict;
11 11 use Test::More tests => 5;
12 12
13 13 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  14 +sub POE::Kernel::TRACE_DEFAULT () { 0 }
  15 +
14 16 use POE;
15 17
16 18 my $sigidle = 0;
8 t/20_resources/00_base/filehandles.pm
... ... @@ -1,10 +1,14 @@
  1 +# vim: ts=2 sw=2 expandtab
1 2 use strict;
2 3
3 4 use lib qw(./mylib ../mylib);
4 5
5 6 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
6   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
7   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  7 +
  8 +BEGIN {
  9 + package POE::Kernel;
  10 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  11 +}
8 12
9 13 use POE;
10 14 use POE::Pipe::TwoWay;
8 t/20_resources/00_base/sessions.pm
... ... @@ -1,11 +1,15 @@
  1 +# vim: ts=2 sw=2 expandtab
1 2 use strict;
2 3
3 4 use lib qw(./mylib ../mylib);
4 5 use Test::More tests => 58;
5 6
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
7   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
8   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  8 +
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
9 13
10 14 BEGIN { use_ok("POE") }
11 15
8 t/20_resources/00_base/sids.pm
... ... @@ -1,11 +1,15 @@
  1 +# vim: ts=2 sw=2 expandtab
1 2 use strict;
2 3
3 4 use lib qw(./mylib ../mylib);
4 5 use Test::More tests => 7;
5 6
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
7   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
8   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  8 +
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
9 13
10 14 BEGIN { use_ok("POE") }
11 15
8 t/20_resources/00_base/signals.pm
... ... @@ -1,11 +1,15 @@
  1 +# vim: ts=2 sw=2 expandtab
1 2 use strict;
2 3
3 4 use lib qw(./mylib ../mylib);
4 5 use Test::More tests => 46;
5 6
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
7   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
8   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  8 +
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
9 13
10 14 BEGIN { use_ok("POE") }
11 15
2  t/90_regression/agaran-filter-httpd.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
6 t/90_regression/averell-callback-ret.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Callback must pass on it's return value as per documentation.
4 5
@@ -8,6 +9,11 @@ use Test::More tests => 2;
8 9
9 10 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
10 11
  12 +BEGIN {
  13 + package POE::Kernel;
  14 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  15 +}
  16 +
11 17 BEGIN { use_ok("POE") } #1
12 18
13 19 BEGIN { $^W = 1 };
2  t/90_regression/bingos-followtail.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
2  t/90_regression/broeren-win32-nbio.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5
2  t/90_regression/cfedde-filter-httpd.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl ts=2 sw=2 expandtab
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
1  t/90_regression/ferrari-server-unix.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Test case supplied by Martin Ferrari as part of rt.cpan.org bug
4 5 # 11262 (Debian bug 292526). Ensures that a previous warning will not
5 t/90_regression/kjeldahl-stop-start-polling.t
... ... @@ -1,13 +1,14 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl ts=2 sw=2 expandtab
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
6 6
7 7 sub POE::Kernel::CATCH_EXCEPTIONS () { 0 }
8   -sub POE::Kernel::ASSERT_DEFAULT () { 1 }
9 8 sub POE::Kernel::USE_SIGCHLD () { 0 }
10 9 sub POE::Kernel::USE_SIGNAL_PIPE () { 0 }
  10 +sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  11 +sub POE::Kernel::TRACE_DEFAULT () { 0 }
11 12
12 13 use POE;
13 14 use POE::Wheel::Run;
5 t/90_regression/kjeldahl-stop-start-sig-nopipe.t
... ... @@ -1,13 +1,14 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl ts=2 sw=2 expandtab
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
6 6
7 7 sub POE::Kernel::CATCH_EXCEPTIONS () { 0 }
8   -sub POE::Kernel::ASSERT_DEFAULT () { 1 }
9 8 sub POE::Kernel::USE_SIGCHLD () { 1 }
10 9 sub POE::Kernel::USE_SIGNAL_PIPE () { 0 }
  10 +sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  11 +sub POE::Kernel::TRACE_DEFAULT () { 0 }
11 12
12 13 use POE;
13 14 use POE::Wheel::Run;
5 t/90_regression/kjeldahl-stop-start-sig-pipe.t
... ... @@ -1,13 +1,14 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl ts=2 sw=2 expandtab
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
6 6
7 7 sub POE::Kernel::CATCH_EXCEPTIONS () { 0 }
8   -sub POE::Kernel::ASSERT_DEFAULT () { 1 }
9 8 sub POE::Kernel::USE_SIGCHLD () { 1 }
10 9 sub POE::Kernel::USE_SIGNAL_PIPE () { 1 }
  10 +sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  11 +sub POE::Kernel::TRACE_DEFAULT () { 0 }
11 12
12 13 use POE;
13 14 use POE::Wheel::Run;
7 t/90_regression/neyuki_detach.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5
@@ -7,6 +8,12 @@ use lib qw(./mylib ../mylib);
7 8 $| = 1;
8 9
9 10 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  11 +
  12 +BEGIN {
  13 + package POE::Kernel;
  14 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  15 +}
  16 +
10 17 use POE;
11 18
12 19 print "1..10\n";
2  t/90_regression/rt14444-arg1.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
8 t/90_regression/rt1648-tied-stderr.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Scott Beck reported that tied STDERR breaks POE::Wheel::Run. He
5 5 # suggested untying STDOUT and STDERR in the child process. This test
@@ -33,6 +33,12 @@ sub DEBUG () { 0 }
33 33 use Test::More tests => 1;
34 34
35 35 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  36 +
  37 +BEGIN {
  38 + package POE::Kernel;
  39 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  40 +}
  41 +
36 42 use POE qw/Wheel::Run Session/;
37 43
38 44 tie *STDERR, 'Test::Tie::Handle';
2  t/90_regression/rt19908-merlyn-stop.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Randal Schwartz reported that die() within _stop causes an infinite
5 5 # loop. He's right. This tests rt.cpan.org ticket 19908.
8 t/90_regression/rt23181-sigchld-rc.t
... ... @@ -1,5 +1,5 @@
1 1 #!perl
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Calling sig_child($pid) without a prior sig_child($pid, $event)
5 5 # would drop the session's reference count below zero.
@@ -9,6 +9,12 @@ use strict;
9 9
10 10 use Test::More tests => 1;
11 11 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
  12 +
  13 +BEGIN {
  14 + package POE::Kernel;
  15 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  16 +}
  17 +
12 18 use POE;
13 19
14 20 POE::Session->create(
2  t/90_regression/rt47966-sigchld.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl ts=2 sw=2 expandtab
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use warnings;
5 5 use strict;
1  t/90_regression/somni-poco-server-tcp.t
... ... @@ -1,3 +1,4 @@
  1 +# vim: ts=2 sw=2 filetype=perl expandtab
1 2 use warnings;
2 3 use strict;
3 4
9 t/90_regression/steinert-passed-wheel.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Passing a POE::Wheel or something into an event handler will cause
5 5 # that thing's destruction to be delayed until outside the session's
@@ -7,9 +7,12 @@
7 7
8 8 use strict;
9 9
10   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
11 10 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
12   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  11 +
  12 +BEGIN {
  13 + package POE::Kernel;
  14 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  15 +}
13 16
14 17 use POE;
15 18 use POE::Wheel::ReadWrite;
9 t/90_regression/suzman_windows.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl -w
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 # Tests various signals using POE's stock signal handlers. These are
5 5 # plain Perl signals, so mileage may vary.
@@ -16,8 +16,11 @@ BEGIN {
16 16 plan tests => 2;
17 17
18 18 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
19   -sub POE::Kernel::TRACE_DEFAULT () { 1 }
20   -sub POE::Kernel::TRACE_FILENAME () { "./test-output.err" }
  19 +
  20 +BEGIN {
  21 + package POE::Kernel;
  22 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  23 +}
21 24
22 25 use POE;
23 26
6 t/90_regression/ton-stop-corruption.t
... ... @@ -1,4 +1,5 @@
1 1 #!/usr/bin/perl -w
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 # Test that stop() does not result in a double garbage collection on
4 5 # the session that called it. This test case provided by Ton Hospel.
@@ -9,6 +10,11 @@ use Test::More tests => 5;
9 10
10 11 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
11 12
  13 +BEGIN {
  14 + package POE::Kernel;
  15 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  16 +}
  17 +
12 18 BEGIN { use_ok("POE") }
13 19 BEGIN { use_ok("POE::Pipe::OneWay") }
14 20
6 t/90_regression/whelan-dieprop.t
... ... @@ -1,10 +1,16 @@
1 1 #!/usr/bin/perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
2 3
3 4 use strict;
4 5 use warnings;
5 6
6 7 sub POE::Kernel::ASSERT_DEFAULT () { 1 }
7 8
  9 +BEGIN {
  10 + package POE::Kernel;
  11 + use constant TRACE_DEFAULT => exists($INC{'Devel/Cover.pm'});
  12 +}
  13 +
8 14 use Test::More tests => 2;
9 15 use POE;
10 16
2  t/90_regression/whjackson-followtail.t
... ... @@ -1,5 +1,5 @@
1 1 #!/usr/bin/perl
2   -# vim: filetype=perl
  2 +# vim: ts=2 sw=2 filetype=perl expandtab
3 3
4 4 use strict;
5 5 use warnings;

0 comments on commit c196b75

Please sign in to comment.
Something went wrong with that request. Please try again.