| line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
|
1
|
|
|
|
|
|
|
package Mason::t::DollarDot; |
|
2
|
|
|
|
|
|
|
$Mason::t::DollarDot::VERSION = '2.23'; |
|
3
|
1
|
|
|
1
|
|
1098
|
use Test::Class::Most parent => 'Mason::Test::Class'; |
|
|
1
|
|
|
|
|
31236
|
|
|
|
1
|
|
|
|
|
6
|
|
|
4
|
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
sub test_dollardot : Tests { |
|
6
|
1
|
|
|
1
|
0
|
646
|
my $self = shift; |
|
7
|
1
|
|
|
|
|
9
|
$self->add_comp( |
|
8
|
|
|
|
|
|
|
path => '/helper.mi', |
|
9
|
|
|
|
|
|
|
src => '<%class>has "foo";</%class> |
|
10
|
|
|
|
|
|
|
Helper: <% $.foo %> |
|
11
|
|
|
|
|
|
|
', |
|
12
|
|
|
|
|
|
|
); |
|
13
|
1
|
|
|
|
|
8
|
$self->test_comp( |
|
14
|
|
|
|
|
|
|
src => ' |
|
15
|
|
|
|
|
|
|
<%class> |
|
16
|
|
|
|
|
|
|
has "name" => ( default => "Joe" ); |
|
17
|
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
</%class> |
|
19
|
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
<%class> |
|
21
|
|
|
|
|
|
|
has "compname"; |
|
22
|
|
|
|
|
|
|
has "date"; |
|
23
|
|
|
|
|
|
|
</%class> |
|
24
|
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
<%method greet> |
|
26
|
|
|
|
|
|
|
Hello, <% $.name %>. Today is <% $.date %>. |
|
27
|
|
|
|
|
|
|
</%method> |
|
28
|
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
% $.greet(); |
|
30
|
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
<& $.compname, foo => $.date &> |
|
32
|
|
|
|
|
|
|
<& /helper.mi, foo => $.name &> |
|
33
|
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
<%init> |
|
35
|
|
|
|
|
|
|
$.date("March 5th"); |
|
36
|
|
|
|
|
|
|
$.compname("helper.mi"); |
|
37
|
|
|
|
|
|
|
</%init> |
|
38
|
|
|
|
|
|
|
', |
|
39
|
|
|
|
|
|
|
expect => ' |
|
40
|
|
|
|
|
|
|
Hello, Joe. Today is March 5th. |
|
41
|
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
Helper: March 5th |
|
43
|
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
Helper: Joe |
|
45
|
|
|
|
|
|
|
', |
|
46
|
|
|
|
|
|
|
); |
|
47
|
1
|
|
|
1
|
|
175
|
} |
|
|
1
|
|
|
|
|
3
|
|
|
|
1
|
|
|
|
|
8
|
|
|
48
|
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
1; |