FindApp/Vars.pm

filter: Statementstmt 100% 28 / 28 Branchbran 50.0% 2 / 4 Conditioncond 37.5% 3 / 8 MC/DCmcdc 0.0% 0 / 5 Subroutinesub 100% 9 / 9 Podpod n/a totaltotal 77.7% 42 / 54 CC 2 SCAR 2.1
CC
2
Cov
82%
BEGIN
2.1
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« FindApp/Utils/Foreign.pm ↑ Summary FindApp/Subs.pm »
1 package FindApp::Vars;
2  
3 6 ▶use v5.10;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 6 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 6 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7 6 ▶use Exporter qw(import);
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 6 ▶BEGIN {
Subroutine BEGIN: called CC=2 SCAR=7.6
10 # Can cause warnings in buggy core Env.pm module otherwise:
11 6 ▶ $ENV{MANPATH} //= q();
Condition50%1/2
$ENV{"MANPATH"} //= ""
l!l
06
MC/DC0%0/1
$ENV{"MANPATH"} //= ""
$ENV{"MANPATH"}
Truth table50%1/2
A
A= $ENV{"MANPATH"}
Aresult
11
00
12 }
13  
14 6 our $VERSION = v1.0;
15  
16 6 ▶my @Internals; BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
17 6 @Internals = qw(
18 $Root
19 $Bin @Bin
20 $Lib @Lib
21 $Man @Man
22 $Debugging
23 $Tracing
24 );
25 }
26  
27 6 ▶my @Externals; BEGIN {
Subroutine BEGIN: called CC=1 SCAR=0.0
28 6 @Externals = qw(
29 $FINDAPP_DEBUG
30 $FINDAPP_DEBUG_SHORTEN
31 $FINDAPP_TRACE
32  
33 @PATH
34 $MANPATH
35 @MANPATH
36  
37 $GIT_DIR
38 $APP_ROOT
39 );
40 }
41  
42 6 ▶use vars @Internals;
Subroutine BEGIN: called CC=1 SCAR=0.0
43 6 ▶use Env @Externals;
Subroutine BEGIN: called CC=1 SCAR=0.0
44  
45 6 our @EXPORT = (@Internals, @Externals);
46 6 our @EXPORT_OK = @EXPORT;
47 6 our %EXPORT_TAGS = (
48 all => \@EXPORT_OK,
49 app => \@Internals,
50 env => \@Externals,
51 );
52  
53 6 ▶$Debugging = $FINDAPP_DEBUG if defined $FINDAPP_DEBUG && !defined $Debugging;
Branch: 1 branch
BranchTrueFalseTotal
if defined $FindApp::Vars::FINDAPP_DEBUG and not defined $FindApp::Vars::Debugging 0 6 6
Condition33%1/3
defined $FindApp::Vars::FINDAPP_DEBUG and not defined $FindApp::Vars::Debugging
!ll&&!rl&&r
600
MC/DC0%0/2
defined $FindApp::Vars::FINDAPP_DEBUG and not defined $FindApp::Vars::Debugging
defined $FindApp::Vars::FINDAPP_DEBUG not defined $FindApp::Vars::Debugging
Truth table33%1/3
A and not(B)
A= defined $FindApp::Vars::FINDAPP_DEBUGB= not defined $FindApp::Vars::Debugging
ABresult
0X0
100
111
54 6 ▶$Tracing = $FINDAPP_TRACE if defined $FINDAPP_TRACE && !defined $Tracing;
Branch: 1 branch
BranchTrueFalseTotal
if defined $FindApp::Vars::FINDAPP_TRACE and not defined $FindApp::Vars::Tracing 0 6 6
Condition33%1/3
defined $FindApp::Vars::FINDAPP_TRACE and not defined $FindApp::Vars::Tracing
!ll&&!rl&&r
600
MC/DC0%0/2
defined $FindApp::Vars::FINDAPP_TRACE and not defined $FindApp::Vars::Tracing
defined $FindApp::Vars::FINDAPP_TRACE not defined $FindApp::Vars::Tracing
Truth table33%1/3
A and not(B)
A= defined $FindApp::Vars::FINDAPP_TRACEB= not defined $FindApp::Vars::Tracing
ABresult
0X0
100
111
55  
56 6 1;
57  
58 =encoding utf8
59  
60 =head1 NAME
61  
62 FindApp::Vars - FIXME
63  
64 =head1 SYNOPSIS
65  
66 use FindApp::Vars;
67  
68 =head1 DESCRIPTION
69  
70 =head2 Public Methods
71  
72 =over
73  
74 =item FIXME
75  
76 =back
77  
78 =head2 Exports
79  
80 =over
81  
82 =item FIXME
83  
84 =back
85  
86 =head1 EXAMPLES
87  
88 =head1 ENVIRONMENT
89  
90 =head1 SEE ALSO
91  
92 =over
93  
94 =item L<FindApp>
95  
96 =back
97  
98 =head1 CAVEATS AND PROVISOS
99  
100 =head1 BUGS AND LIMITATIONS
101  
102 =head1 HISTORY
103  
104 =head1 AUTHOR
105  
106 Tom Christiansen << <tchrist@perl.com> >>
107  
108 =head1 LICENCE AND COPYRIGHT
109  
110 Copyright (c) 2016, Tom Christiansen C<< <tchrist@perl.com> >>.
111 All Rights Reserved.
112  
113 This module is free software; you can redistribute it and/or
114 modify it under the same terms as Perl itself. See L<perlartistic>.
115  
116 =cut
117  
« FindApp/Utils/Foreign.pm ↑ Summary FindApp/Subs.pm »