| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package Test::Able::Object; |
|
2
|
|
|
|
|
|
|
|
|
3
|
8
|
|
|
8
|
|
34
|
use Moose; |
|
|
8
|
|
|
|
|
10
|
|
|
|
8
|
|
|
|
|
44
|
|
|
4
|
8
|
|
|
8
|
|
38003
|
use strict; |
|
|
8
|
|
|
|
|
15
|
|
|
|
8
|
|
|
|
|
211
|
|
|
5
|
8
|
|
|
8
|
|
30
|
use warnings; |
|
|
8
|
|
|
|
|
9
|
|
|
|
8
|
|
|
|
|
1238
|
|
|
6
|
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
extends( 'Moose::Object' ); |
|
8
|
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
=head1 NAME |
|
10
|
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
Test::Able::Object - Test::Able's base object |
|
12
|
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
=cut |
|
14
|
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
=head1 DESCRIPTION |
|
16
|
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
This object serves the same purpose as, and is a subclass of, |
|
18
|
|
|
|
|
|
|
Moose::Object. |
|
19
|
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=head1 METHODS |
|
21
|
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
=over |
|
23
|
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=item BUILD |
|
25
|
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
Standard Moose BUILD method that builds all the test-related method |
|
27
|
|
|
|
|
|
|
lists. |
|
28
|
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=cut |
|
30
|
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub BUILD { |
|
32
|
37
|
|
|
37
|
1
|
35530
|
my ( $self, ) = @_; |
|
33
|
|
|
|
|
|
|
|
|
34
|
37
|
|
|
|
|
133
|
$self->meta->current_test_object( $self, ); |
|
35
|
37
|
|
|
|
|
106
|
$self->meta->build_all_methods; |
|
36
|
37
|
|
|
|
|
116
|
$self->meta->clear_current_test_object; |
|
37
|
|
|
|
|
|
|
|
|
38
|
37
|
|
|
|
|
108
|
return; |
|
39
|
|
|
|
|
|
|
} |
|
40
|
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=item run_tests |
|
42
|
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
A convenience method around L<Test::Able::Role::Meta::Class/run_tests>. Can |
|
44
|
|
|
|
|
|
|
be called as a class or instance method. |
|
45
|
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
=back |
|
47
|
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
=cut |
|
49
|
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
sub run_tests { |
|
51
|
26
|
|
|
26
|
1
|
146
|
my ( $proto, ) = @_; |
|
52
|
|
|
|
|
|
|
|
|
53
|
26
|
100
|
|
|
|
90
|
my $self = ref $proto ? $proto : $proto->new; |
|
54
|
26
|
|
|
|
|
84
|
$self->meta->current_test_object( $self, ); |
|
55
|
26
|
|
|
|
|
82
|
$self->meta->run_tests; |
|
56
|
24
|
|
|
|
|
107
|
$self->meta->clear_current_test_object; |
|
57
|
|
|
|
|
|
|
|
|
58
|
24
|
|
|
|
|
156
|
return; |
|
59
|
|
|
|
|
|
|
} |
|
60
|
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=head1 AUTHOR |
|
62
|
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Justin DeVuyst, C<justin@devuyst.com> |
|
64
|
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
|
66
|
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
Copyright 2009 by Justin DeVuyst. |
|
68
|
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
This library is free software, you can redistribute it and/or modify it under |
|
70
|
|
|
|
|
|
|
the same terms as Perl itself. |
|
71
|
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=cut |
|
73
|
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
1; |