line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
1
|
|
|
1
|
|
27277
|
use 5.006; |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
40
|
|
2
|
1
|
|
|
1
|
|
6
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
45
|
|
3
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
53
|
|
4
|
|
|
|
|
|
|
package Test::Filename; |
5
|
|
|
|
|
|
|
# ABSTRACT: Portable filename comparison |
6
|
|
|
|
|
|
|
our $VERSION = '0.03'; # VERSION |
7
|
|
|
|
|
|
|
|
8
|
1
|
|
|
1
|
|
1341
|
use Test::Builder::Module; |
|
1
|
|
|
|
|
583
|
|
|
1
|
|
|
|
|
7
|
|
9
|
1
|
|
|
1
|
|
1141
|
use Path::Tiny; |
|
1
|
|
|
|
|
20493
|
|
|
1
|
|
|
|
|
718
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
our @ISA = qw/Test::Builder::Module/; |
12
|
|
|
|
|
|
|
our @EXPORT = qw( |
13
|
|
|
|
|
|
|
filename_is |
14
|
|
|
|
|
|
|
filename_isnt |
15
|
|
|
|
|
|
|
); |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
my $CLASS = __PACKAGE__; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
#--------------------------------------------------------------------------# |
20
|
|
|
|
|
|
|
# public API |
21
|
|
|
|
|
|
|
#--------------------------------------------------------------------------# |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub filename_is { |
24
|
2
|
|
|
2
|
1
|
4793
|
my($got, $expected, $label) = @_; |
25
|
2
|
|
|
|
|
18
|
return $CLASS->builder->is_eq(path($got), path($expected), $label); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub filename_isnt { |
29
|
2
|
|
|
2
|
1
|
9603
|
my($got, $expected, $label) = @_; |
30
|
2
|
|
|
|
|
15
|
return $CLASS->builder->isnt_eq(path($got), path($expected), $label); |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
1; |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
__END__ |