lib/Rex/Interface/Connection/Fake.pm

filter: Statementstmt 92.5% 25 / 27 Branchbran n/a Conditioncond 33.3% 1 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 84.6% 11 / 13 Podpod 0.0% 0 / 9 totaltotal 68.5% 37 / 54 CC 2 SCAR 2.0
CC
2
Cov
87%
new
2.1
get_fs_connection_object
2.0
BEGIN
1.0
CRAP 1.2
« lib/Rex/Commands/Inventory.pm ↑ Summary lib/Rex/Commands/Notify.pm »
1 #
2 # (c) Jan Gehring <jan.gehring@gmail.com>
3 #
4  
5 package Rex::Interface::Connection::Fake;
6  
7 3 ▶use v5.14.4;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 3 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 3 our $VERSION = '1.16.1'; # VERSION
11  
12 3 ▶use Rex::Interface::Connection::Base;
Subroutine BEGIN: called CC=1 SCAR=0.0
13  
14 3 ▶use base qw(Rex::Interface::Connection::Base);
Subroutine BEGIN: called CC=1 SCAR=0.0
15  
16 4 ▶sub new {
Subroutine new: called CC=2 SCAR=7.2
Pod undocumented
17 4 my $that = shift;
18 4 ▶ my $proto = ref($that) || $that;
Condition33%1/3
ref $that || $that
l!l&&r!l&&!r
040
MC/DC0%0/2
ref $that || $that
ref $that $that
Truth table33%1/3
A || B
A= ref $thatB= $that
ABresult
1X1
011
000
19 4 my $self = $that->SUPER::new(@_);
20  
21 4 bless( $self, $proto );
22  
23 4 return $self;
24 }
25  
26 0 ▶sub error { }
Subroutine error: not called CC=1 SCAR=0.0
Pod undocumented
27  
28 3 ▶sub connect {
Subroutine connect: called CC=1 SCAR=0.0
Pod undocumented
29 3 my ( $self, %option ) = @_;
30 3 $self->{server} = $option{server};
31 }
32  
33 2 ▶sub disconnect { }
Subroutine disconnect: called CC=1 SCAR=0.0
Pod undocumented
34 3 ▶sub get_connection_object { my ($self) = @_; return $self; }
Subroutine get_connection_object: called CC=1 SCAR=0.0
Pod undocumented
35 0 ▶sub get_fs_connection_object { my ($self) = @_; return $self; }
Subroutine get_fs_connection_object: not called CC=1 SCAR=6.9
Pod undocumented
36 4 ▶sub is_connected { return 1; }
Subroutine is_connected: called CC=1 SCAR=0.0
Pod undocumented
37 3 ▶sub is_authenticated { return 1; }
Subroutine is_authenticated: called CC=1 SCAR=0.0
Pod undocumented
38  
39 11 ▶sub get_connection_type { return "Local"; }
Subroutine get_connection_type: called CC=1 SCAR=0.0
Pod undocumented
40  
41 3 1;
« lib/Rex/Commands/Inventory.pm ↑ Summary lib/Rex/Commands/Notify.pm »