File Coverage

inc/TestML.pm
Criterion Covered Total %
statement 18 20 90.0
branch 4 8 50.0
condition n/a
subroutine 3 3 100.0
pod 0 2 0.0
total 25 33 75.7


line stmt bran cond sub pod time code
1             package TestML;
2              
3 3     3   36383 use TestML::Base;
  3         7  
  3         14  
4             our $VERSION = '0.52';
5              
6             has runtime => ();
7             has compiler => ();
8             has bridge => ();
9             has library => ();
10             has testml => ();
11              
12             sub run {
13 1     1 0 2 my ($self) = @_;
14 1         2 $self->set_default_classes;
15 1         4 $self->runtime->new(
16             compiler => $self->compiler,
17             bridge => $self->bridge,
18             library => $self->library,
19             testml => $self->testml,
20             )->run;
21             }
22              
23             sub set_default_classes {
24 1     1 0 2 my ($self) = @_;
25 1 50       3 if (not $self->runtime) {
26 1         249 require TestML::Runtime::TAP;
27 1         7 $self->{runtime} = 'TestML::Runtime::TAP';
28             }
29 1 50       5 if (not $self->compiler) {
30 1         286 require TestML::Compiler::Pegex;
31 1         10 $self->{compiler} = 'TestML::Compiler::Pegex';
32             }
33 1 50       5 if (not $self->bridge) {
34 0         0 require TestML::Bridge;
35 0         0 $self->{bridge} = 'TestML::Bridge';
36             }
37 1 50       4 if (not $self->library) {
38 1         277 require TestML::Library::Standard;
39 1         280 require TestML::Library::Debug;
40 1         5 $self->{library} = [
41             'TestML::Library::Standard',
42             'TestML::Library::Debug',
43             ];
44             }
45             }
46              
47             1;