meta/FunctionalPerl/TailExpand.pm

filter: Statementstmt 100% 20 / 20 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 6 / 6 Podpod n/a totaltotal 100% 26 / 26 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« lib/PXML/Serialize/t.pm ↑ Summary meta/test.pl »
1 #
2 # Copyright (c) 2019 Christian Jaeger, copying@christianjaeger.ch
3 #
4 # This is free software, offered under either the same terms as perl 5
5 # or the terms of the Artistic License version 2 or the terms of the
6 # MIT License (Expat version). See the file COPYING.md that came
7 # bundled with this file.
8 #
9  
10 =head1 NAME
11  
12 FunctionalPerl::TailExpand
13  
14 =head1 SYNOPSIS
15  
16 =for test ignore
17  
18 use lib "./meta";
19 use FunctionalPerl::TailExpand;
20 use FunctionalPerl::Htmlgen::Nav; # or whatever other modules use tail
21  
22 =head1 DESCRIPTION
23  
24 Avoid dependency on L<Sub::Call::Tail> by running C<bin/expand-tail>
25 on all modules (that can contain C<tail> calls) first.
26  
27 Automatically runs C<use lib "./.htmlgen";> etc. to have subsequent
28 module loads happen from the expanded files.
29  
30 Can only be run with the current working directory being the root of
31 the source repository, i.e. during testing (or build).
32  
33 =cut
34  
35 package FunctionalPerl::TailExpand;
36  
37 3 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
38 3 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
39 3 ▶use warnings FATAL => 'uninitialized';
Subroutine BEGIN: called CC=1 SCAR=0.0
40  
41 3 ▶use lib "./lib";
Subroutine BEGIN: called CC=1 SCAR=0.0
42 3 ▶use Chj::xperlfunc ":all";
Subroutine BEGIN: called CC=1 SCAR=0.0
43  
44 3 xxsystem_safe $^X, "meta/tail-expand";
45  
46 3 ▶use lib "./.htmlgen";
Subroutine BEGIN: called CC=1 SCAR=0.0
47  
48 # no need; skipped in meta/tail-expand
49 # use lib "./.lib";
50 # use lib "./.meta";
51  
52 # normal load paths, to be transparent re what should be loaded
53 # use lib "./meta"; no need as that had to be done already to reach us
54  
55 3 1
« lib/PXML/Serialize/t.pm ↑ Summary meta/test.pl »