Installer/Utils/Linux.pm untested

filter: Statementstmt 0.0% 0 / 31 Branchbran 0.0% 0 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 8 Podpod 0.0% 0 / 1 totaltotal 0.0% 0 / 44 CC 3 SCAR 16.1
CC
3
Cov
0%
_find_path
12.0
BEGIN
2.0
BEGIN
2.0
CRAP 5.0
1 package OPM::Installer::Utils::Linux;
2  
3 # ABSTRACT: helper functions for ticketsystem addon installations on Linux
4  
5 use strict;
6 use warnings;
7  
8 our $VERSION = '1.0.1'; # VERSION
9  
10 use Moo::Role;
11  
12 use File::Spec;
13 use File::Basename;
14 use List::Util qw(first);
15 use File::Glob qw(bsd_glob);
16  
17 sub _find_path {
18 my ($self) = @_;
19  
20 my @checks = qw(/opt/otrs /srv/otrs /etc/otrs);
21 my ($testdir) = grep { -d $_ }@checks;
22  
23 return $testdir if $testdir;
24  
25 # try to find apache installation and read from config
26 my ($apachedir) = grep{ -d $_ }qw(/etc/apache2 /etc/httpd);
27 return if !$apachedir;
28  
29
30 }
31  
32 1;
33  
34 __END__