Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

82 lines (63 sloc) 2.869 kB
Reading database from ...
------------------------------------------ ------ ------ ------ ------ ------
File stmt bran cond sub total
------------------------------------------ ------ ------ ------ ------ ------
tests/cond_chained 100.0 83.3 86.7 100.0 90.9
Total 100.0 83.3 86.7 100.0 90.9
------------------------------------------ ------ ------ ------ ------ ------
Run: ...
Perl version: ...
OS: ...
Start: ...
Finish: ...
tests/cond_chained
line err stmt bran cond sub code
1 #!/usr/bin/perl
2
3 sub t1 {
4 1 1 for my $x (0, 1, 2) {
5 3 100 100 my $y = 3 if $x && $x == 2;
6 }
7 }
8
9 sub t2 {
10 1 1 for my $x (0, 1, 2) {
11 3 100 100 return if $x && $x == 2;
12 }
13 }
14
15 sub t3 {
16 1 1 for my $x (0, 1, 2) {
17 *** 3 50 100 last if $x && $x == 2 && $x == 2 && $x == 2;
*** 66
*** 66
18 }
19 }
20
21 1 t1;
22 1 t2;
23 1 t3;
Branches
--------
line err % true false branch
----- --- ------ ------ ------ ------
5 100 1 2 if $x and $x == 2
11 100 1 2 if $x and $x == 2
17 *** 50 1 0 if $x and $x == 2 and $x == 2 and $x == 2
Conditions
----------
and 3 conditions
line err % !l l&&!r l&&r expr
----- --- ------ ------ ------ ------ ----
5 100 1 1 1 $x and $x == 2
11 100 1 1 1 $x and $x == 2
17 100 1 1 1 $x and $x == 2
*** 66 2 0 1 $x and $x == 2 and $x == 2
*** 66 1 0 1 $x and $x == 2 and $x == 2 and $x == 2
Covered Subroutines
-------------------
Subroutine Count Location
---------- ----- ---------------------
t1 1 tests/cond_chained:4
t2 1 tests/cond_chained:10
t3 1 tests/cond_chained:16
Jump to Line
Something went wrong with that request. Please try again.