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 4     4   71258 use TestML::Base;
  4         10  
  4         23  
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 4     4 0 11 my ($self) = @_;
14 4         22 $self->set_default_classes;
15 4         26 $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 4     4 0 10 my ($self) = @_;
25 4 50       24 if (not $self->runtime) {
26 4         2090 require TestML::Runtime::TAP;
27 4         49 $self->{runtime} = 'TestML::Runtime::TAP';
28             }
29 4 50       26 if (not $self->compiler) {
30 4         1932 require TestML::Compiler::Pegex;
31 4         25 $self->{compiler} = 'TestML::Compiler::Pegex';
32             }
33 4 50       27 if (not $self->bridge) {
34 0         0 require TestML::Bridge;
35 0         0 $self->{bridge} = 'TestML::Bridge';
36             }
37 4 50       19 if (not $self->library) {
38 4         2359 require TestML::Library::Standard;
39 4         2013 require TestML::Library::Debug;
40 4         40 $self->{library} = [
41             'TestML::Library::Standard',
42             'TestML::Library::Debug',
43             ];
44             }
45             }
46              
47             1;