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   55440 use TestML::Base;
  3         9  
  3         15  
4             our $VERSION = '0.49';
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         5 $self->set_default_classes;
15 1         14 $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       5 if (not $self->runtime) {
26 1         436 require TestML::Runtime::TAP;
27 1         11 $self->{runtime} = 'TestML::Runtime::TAP';
28             }
29 1 50       6 if (not $self->compiler) {
30 1         450 require TestML::Compiler::Pegex;
31 1         6 $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       5 if (not $self->library) {
38 1         497 require TestML::Library::Standard;
39 1         640 require TestML::Library::Debug;
40 1         9 $self->{library} = [
41             'TestML::Library::Standard',
42             'TestML::Library::Debug',
43             ];
44             }
45             }
46              
47             1;