line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Test::More::Unlike; |
2
|
2
|
|
|
2
|
|
70135
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
87
|
|
3
|
2
|
|
|
2
|
|
22
|
use warnings; |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
69
|
|
4
|
2
|
|
|
2
|
|
11
|
use Test::More qw//; |
|
2
|
|
|
|
|
9
|
|
|
2
|
|
|
|
|
102
|
|
5
|
2
|
|
|
2
|
|
1872
|
use Text::MatchedPosition; |
|
2
|
|
|
|
|
3481
|
|
|
2
|
|
|
|
|
158
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
our $VERSION = '0.03'; |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub import { |
10
|
2
|
|
|
2
|
|
17
|
my $class = shift; |
11
|
2
|
|
|
|
|
7
|
my $package = caller(0); |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
{ |
14
|
2
|
|
|
2
|
|
12
|
no strict 'refs'; ## no critic |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
68
|
|
|
2
|
|
|
|
|
4
|
|
15
|
2
|
|
|
2
|
|
10
|
no warnings 'redefine'; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
381
|
|
16
|
2
|
|
|
|
|
3
|
*{"$package\::unlike"} = \&{ __PACKAGE__ . '::_unlike' }; |
|
2
|
|
|
|
|
1639
|
|
|
2
|
|
|
|
|
7
|
|
17
|
|
|
|
|
|
|
} |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub _unlike ($$;$) { ## no critic (Subroutines::ProhibitSubroutinePrototypes) |
21
|
0
|
|
|
0
|
|
|
my $tb = Test::More->builder; |
22
|
0
|
|
|
|
|
|
my $ret = $tb->unlike(@_); |
23
|
0
|
0
|
|
|
|
|
return $ret if $ret eq '1'; |
24
|
|
|
|
|
|
|
|
25
|
0
|
|
|
|
|
|
my $pos = Text::MatchedPosition->new(@_); |
26
|
0
|
|
|
|
|
|
return $tb->diag( sprintf <<'DIAGNOSTIC', $pos->line, $pos->offset ); |
27
|
|
|
|
|
|
|
matched at line: %d, offset: %d |
28
|
|
|
|
|
|
|
DIAGNOSTIC |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
1; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
__END__ |