| line | stmt | bran | cond | sub | pod | time | code | 
| 1 |  |  |  |  |  |  | package Test::Stream::Plugin::CanFork; | 
| 2 | 2 |  |  | 2 |  | 10 | use strict; | 
|  | 2 |  |  |  |  | 2 |  | 
|  | 2 |  |  |  |  | 56 |  | 
| 3 | 2 |  |  | 2 |  | 10 | use warnings; | 
|  | 2 |  |  |  |  | 4 |  | 
|  | 2 |  |  |  |  | 58 |  | 
| 4 |  |  |  |  |  |  |  | 
| 5 | 2 |  |  | 2 |  | 12 | use Test::Stream::Capabilities qw/CAN_FORK CAN_REALLY_FORK/; | 
|  | 2 |  |  |  |  | 2 |  | 
|  | 2 |  |  |  |  | 18 |  | 
| 6 |  |  |  |  |  |  |  | 
| 7 | 2 |  |  | 2 |  | 10 | use Test::Stream::Plugin; | 
|  | 2 |  |  |  |  | 4 |  | 
|  | 2 |  |  |  |  | 14 |  | 
| 8 |  |  |  |  |  |  |  | 
| 9 |  |  |  |  |  |  | sub load_ts_plugin { | 
| 10 | 2 |  |  | 2 | 0 | 6 | my $class = shift; | 
| 11 | 2 |  |  |  |  | 6 | my ($caller, %params) = @_; | 
| 12 |  |  |  |  |  |  |  | 
| 13 | 2 | 50 |  |  |  | 6 | if ($params{real}) { | 
| 14 | 0 |  |  |  |  | 0 | return if CAN_REALLY_FORK; | 
| 15 |  |  |  |  |  |  | } | 
| 16 |  |  |  |  |  |  | else { | 
| 17 | 2 |  |  |  |  | 12 | return if CAN_FORK; | 
| 18 |  |  |  |  |  |  | } | 
| 19 |  |  |  |  |  |  |  | 
| 20 | 0 |  |  |  |  |  | require Test::Stream::Context; | 
| 21 | 0 |  |  |  |  |  | my $ctx = Test::Stream::Context::context(); | 
| 22 | 0 |  |  |  |  |  | $ctx->plan(0, "SKIP", "This test requires a perl capable of forking."); | 
| 23 | 0 |  |  |  |  |  | $ctx->release; | 
| 24 | 0 |  |  |  |  |  | exit 0; | 
| 25 |  |  |  |  |  |  | } | 
| 26 |  |  |  |  |  |  |  | 
| 27 |  |  |  |  |  |  | 1; | 
| 28 |  |  |  |  |  |  |  | 
| 29 |  |  |  |  |  |  | __END__ |