blib/lib/App/Prove/Elasticsearch/Blamer/System.pm

filter: Statementstmt 88.8% 16 / 18 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod 100% 1 / 1 totaltotal 88.0% 22 / 25 CC 1 SCAR 1.5
CC
1
Cov
89%
_get_uname
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« blib/lib/App/ape.pm ↑ Summary blib/lib/App/Prove/Elasticsearch/Indexer/MMDist.pm »
1 # ABSTRACT: Determine the responsible party for tests via system user & hostname for upload to elasticsearch
2 # PODNAME: App::Prove::Elasticsearch::Blamer::Env
3  
4 package App::Prove::Elasticsearch::Blamer::System;
5 2 $App::Prove::Elasticsearch::Blamer::System::VERSION = '0.001';
6 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 2 ▶use utf8;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 2 ▶use System::Info;
Subroutine BEGIN: called CC=1 SCAR=0.0
11  
12 1 ▶sub get_responsible_party {
Subroutine get_responsible_party: called CC=1 SCAR=0.0
Pod documented
13 1 my $info = System::Info->sysinfo_hash();
14 1 return _get_uname() . '@' . $info->{hostname};
15 }
16  
17 0 ▶sub _get_uname {
Subroutine _get_uname: not called CC=1 SCAR=6.9
18 0 my @pw_info = getpwuid($<);
19 0 return $pw_info[0];
20 }
21  
22 2 1;
23  
24 __END__
« blib/lib/App/ape.pm ↑ Summary blib/lib/App/Prove/Elasticsearch/Indexer/MMDist.pm »