line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package CHI::t::Driver::Subcache::mirror_cache; |
2
|
|
|
|
|
|
|
$CHI::t::Driver::Subcache::mirror_cache::VERSION = '0.61'; |
3
|
1
|
|
|
1
|
|
458
|
use strict; |
|
1
|
|
|
|
|
8
|
|
|
1
|
|
|
|
|
30
|
|
4
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
25
|
|
5
|
1
|
|
|
1
|
|
389
|
use CHI::Test; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
7
|
|
6
|
1
|
|
|
1
|
|
740
|
use File::Temp qw(tempdir); |
|
1
|
|
|
|
|
18706
|
|
|
1
|
|
|
|
|
67
|
|
7
|
1
|
|
|
1
|
|
9
|
use base qw(CHI::t::Driver::Subcache); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
485
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
my $root_dir; |
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub testing_driver_class { |
12
|
80
|
|
|
80
|
0
|
725
|
return 'CHI::Driver::File'; |
13
|
|
|
|
|
|
|
} |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
sub new_cache_options { |
16
|
80
|
|
|
80
|
0
|
147
|
my $self = shift; |
17
|
|
|
|
|
|
|
|
18
|
80
|
|
66
|
|
|
206
|
$root_dir ||= |
19
|
|
|
|
|
|
|
tempdir( "chi-driver-subcache-mirror-XXXX", TMPDIR => 1, CLEANUP => 1 ); |
20
|
|
|
|
|
|
|
return ( |
21
|
80
|
|
|
|
|
941
|
$self->SUPER::new_cache_options(), |
22
|
|
|
|
|
|
|
depth => 2, |
23
|
|
|
|
|
|
|
root_dir => $root_dir, |
24
|
|
|
|
|
|
|
mirror_to_cache => { driver => 'File', depth => 3 }, |
25
|
|
|
|
|
|
|
); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
# This tries to create its own mirror cache |
29
|
|
|
|
1
|
0
|
|
sub test_max_key_length { } |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
1; |