Template/ESCAPE/JS.pm

filter: Statementstmt 100% 19 / 19 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 4 / 4 Podpod 0.0% 0 / 1 totaltotal 92.3% 24 / 26 CC 2 SCAR 3.4
CC
2
Cov
95%
output
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.4
« Template/ESCAPE/URL.pm ↑ Summary Template/ESCAPE.pm »
1 package HTML::Template::ESCAPE::JS;
2 5 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 5 ▶use warnings FATAL => 'all';
Subroutine BEGIN: called CC=1 SCAR=0.0
4 5 ▶use base qw(HTML::Template::ESCAPE);
Subroutine BEGIN: called CC=1 SCAR=0.0
5 5 our $VERSION = '2.9';
6  
7 23 ▶sub output {
Subroutine output: called CC=2 SCAR=7.0
Pod undocumented
8 23 my $self = shift;
9 23 ▶ $_ = shift if (@_ > 0);
Branch: 1 branch
BranchTrueFalseTotal
if @_ > 0 23 0 23
10 23 s/\\/\\\\/g;
11 23 s/'/\\'/g;
12 23 s/"/\\"/g;
13 23 s/\n/\\n/g;
14 23 s/\r/\\r/g;
15 23 $_;
16 }
17  
18 5 1;
« Template/ESCAPE/URL.pm ↑ Summary Template/ESCAPE.pm »