Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

101 lines (82 sloc) 3.683 kb
Reading database from ...
------------------------------------------ ------ ------ ------ ------ ------
File stmt bran cond sub total
------------------------------------------ ------ ------ ------ ------ ------
tests/t0 94.1 62.5 66.7 100.0 83.3
Total 94.1 62.5 66.7 100.0 83.3
------------------------------------------ ------ ------ ------ ------ ------
Run: ...
Perl version: ...
OS: ...
Start: ...
Finish: ...
tests/t0
line err stmt bran cond sub code
1 #!/usr/bin/perl
2
3 # Copyright 2002-2012, Paul Johnson (paul@pjcj.net)
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 1 1 use strict;
1
1
11 1 1 use warnings;
1
1
12
13 1 my @x;
14
15 1 my $y = 1;
16
17 1 for (0 .. 10)
18 {
19 *** 11 50 $y &&
20 $x[1]++;
21
22 *** 11 100 66 $y &&
23 $x[0]++ &&
24 $x[1]++;
25
26 *** 11 50 $x[2]++
27 if $y;
28
29 11 for (0 .. 2)
30 {
31 33 $x[3]++;
32 }
33
34 *** 11 50 if ($y)
35 {
36 11 $x[4]++;
37 }
38 else
39 {
40 *** 0 $x[5]++;
41 }
42 }
43
44 # print join(", ", @x), "\n";
Branches
--------
line err % true false branch
----- --- ------ ------ ------ ------
19 *** 50 11 0 if $y
22 100 10 1 if $y and $x[0]++
26 *** 50 11 0 if $y
34 *** 50 11 0 if ($y) { }
Conditions
----------
and 3 conditions
line err % !l l&&!r l&&r expr
----- --- ------ ------ ------ ------ ----
22 *** 66 0 1 10 $y and $x[0]++
Covered Subroutines
-------------------
Subroutine Count Location
---------- ----- -----------
BEGIN 1 tests/t0:10
BEGIN 1 tests/t0:11
Jump to Line
Something went wrong with that request. Please try again.