Perlito5X/Test2/Event/Bail.pm untested

filter: Statementstmt 0.0% 0 / 21 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 11 Podpod 0.0% 0 / 7 totaltotal 0.0% 0 / 41 CC 2 SCAR 9.8
CC
2
Cov
0%
summary
6.0
BEGIN
2.0
callback
2.0
CRAP 2.7
1 package Test2::Event::Bail;
2 use strict;
3 use warnings;
4  
5 our $VERSION = '1.302073';
6  
7  
8 BEGIN { require Test2::Event; our @ISA = qw(Test2::Event) }
9 use Test2::Util::HashBase qw{reason};
10  
11 sub callback {
12 my $self = shift;
13 my ($hub) = @_;
14  
15 $hub->set_bailed_out($self);
16 }
17  
18 # Make sure the tests terminate
19 sub terminate { 255 };
20  
21 sub global { 1 };
22  
23 sub causes_fail { 1 }
24  
25 sub summary {
26 my $self = shift;
27 return "Bail out! " . $self->{+REASON}
28 if $self->{+REASON};
29  
30 return "Bail out!";
31 }
32  
33 sub diagnostics { 1 }
34  
35 1;
36  
37 __END__