Interpreter.pm

filter: Statementstmt 88.0% 22 / 25 Branchbran 50.0% 1 / 2 Conditioncond 33.3% 1 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 66.6% 6 / 9 Podpod 100% 4 / 4 totaltotal 75.5% 34 / 45 CC 3 SCAR 6.5
CC
3
Cov
80%
new
3.3
position
2.0
stats
2.0
CRAP 1.9
« Interpreter/Ultimaker.pm ↑ Summary
1 package Gcode::Interpreter;
2  
3 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 5 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 5 ▶use Exporter;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 5 ▶use vars qw($VERSION @ISA);
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 5 $VERSION = 1.0.1;
10 5 @ISA = qw(Exporter);
11  
12 5 ▶use Gcode::Interpreter::Ultimaker;
Subroutine BEGIN: called CC=1 SCAR=0.0
13  
14 7 ▶sub new {
Subroutine new: called CC=3 SCAR=12.0
Pod documented
15 7 my $class = shift(@_);
16  
17 7 my $machine_type = shift(@_);
18  
19 7 ▶ die "Unsupported machine type '$machine_type'\n" if($machine_type && $machine_type ne 'Ultimaker');
Branch: 1 branch
BranchTrueFalseTotal
if $machine_type and $machine_type ne "Ultimaker" 0 7 7
Condition33%1/3
$machine_type and $machine_type ne "Ultimaker"
!ll&&!rl&&r
700
MC/DC0%0/2
$machine_type and $machine_type ne "Ultimaker"
$machine_type $machine_type ne "Ultimaker"
Truth table33%1/3
A and B
A= $machine_typeB= $machine_type ne "Ultimaker"
ABresult
0X0
100
111
20  
21 7 return Gcode::Interpreter::Ultimaker->new(@_);
22 }
23  
24 0 ▶sub position {
Subroutine position: not called CC=1 SCAR=6.9
Pod documented
25 0 return [undef,undef,undef,undef];
26 }
27  
28 0 ▶sub stats {
Subroutine stats: not called CC=1 SCAR=6.9
Pod documented
29 0 return {'duration' => undef, 'extruded' => undef};
30 }
31  
32 0 ▶sub process_line {
Subroutine process_line: not called CC=1 SCAR=6.9
Pod documented
33 0 return 0;
34 }
35  
36 5 1;
37  
38 __END__
« Interpreter/Ultimaker.pm ↑ Summary