Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 54 lines (38 sloc) 1.172 kB
5309600 @pjcj Test against perl-5.8.7.
authored
1 #!/usr/bin/perl
2
c7f77d4 @pjcj I think my canonical mail address is here to stay.
authored
3 # Copyright 2004-2012, Paul Johnson (paul@pjcj.net)
5309600 @pjcj Test against perl-5.8.7.
authored
4
5 # This software is free. It is licensed under the same terms as Perl itself.
6
7 # The latest version of this software should be available from my homepage:
8 # http://www.pjcj.net
9
10 use strict;
11 use warnings;
12
b9e1fe5 @wchristian removed explicit versions in use statements
wchristian authored
13 use Devel::Cover::Test;
5309600 @pjcj Test against perl-5.8.7.
authored
14
8a94655 @pjcj 5.8.7 is crashing with forks and evals.
authored
15 if ($] == 5.008007)
16 {
17 eval "use Test::More skip_all => 'Crashes 5.8.7'";
18 exit;
19 }
20
5309600 @pjcj Test against perl-5.8.7.
authored
21 my $run_test = sub
22 {
23 my $test = shift;
24
25 $test->{test_file_parameters} = "5";
26 $test->run_command($test->test_command);
27
28 $test->{test_parameters} .= " -merge 1";
29
30 $test->{test_file_parameters} = "5";
31 $test->run_command($test->test_command);
32
33 $test->{test_file_parameters} = "7";
34 $test->run_command($test->test_command);
35
36 $test->{test_file_parameters} = "0";
37 $test->run_command($test->test_command);
38 };
39
40 my $runs = 4;
41
2c0be70 @pjcj Fix up creation of golden files.
authored
42 my $test = Devel::Cover::Test->new
5309600 @pjcj Test against perl-5.8.7.
authored
43 (
44 "eval3",
45 golden_test => "eval_sub.t",
46 run_test => $run_test,
8af917d @pjcj Make __COVER__ keys arrays.
authored
47 changes => [ 'if (/^Run: /) { $get_line->() for 1 .. 5; redo }' ],
5309600 @pjcj Test against perl-5.8.7.
authored
48 tests => sub { $_[0] - $runs * 6 }, # number of lines deleted above
2c0be70 @pjcj Fix up creation of golden files.
authored
49 );
37e017d @pjcj Remove some warnings.
authored
50
2c0be70 @pjcj Fix up creation of golden files.
authored
51 $test->run_test;
37e017d @pjcj Remove some warnings.
authored
52 no warnings;
2c0be70 @pjcj Fix up creation of golden files.
authored
53 $test # for create_gold
Something went wrong with that request. Please try again.