Skip to content

Commit 8c4039a

Browse files
committed
capture Lvalue auto-doc in t/pp_pod.t
1 parent 5fef68f commit 8c4039a

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

t/pp_pod.t

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,19 @@ subtest a_b => sub {
142142
ok all_seen($obj, 'foo'), 'all seen';
143143
};
144144

145+
subtest a_bl => sub {
146+
my $obj = call_pp_def(foo =>
147+
Pars => 'a(n); [o]b(n)',
148+
Lvalue => 1,
149+
);
150+
ok find_usage($obj, '$b = foo($a)'), 'function call w/ arg';
151+
ok find_usage($obj, 'foo($a, $b)'), 'all arguments given';
152+
ok find_usage($obj, '$b = $a->foo'), 'method call';
153+
ok find_usage($obj, '$a->foo($b)'), 'method call, arg';
154+
ok find_usage($obj, '$a->foo .= $data'), 'method call, lvalue';
155+
ok all_seen($obj, 'foo'), 'all seen';
156+
};
157+
145158
subtest a_b_k => sub {
146159
my $obj = call_pp_def(foo =>
147160
Pars => 'a(n); [o]b(n)',

0 commit comments

Comments
 (0)