Debian Codegraph @

t/41parts-attrs.t

raw
1 #!/usr/bin/perl
2
3 use v5.14;
4 use warnings;
5
6 use Test2::V0;
7
8 use lib "t";
9 use testcase "t::parts";
10
11 # attrs optional
12 {
13 parts NAME { }
14
15 parts ANAME :method { }
16
17 pass( 'Optional attributes permitted but not required' );
18 }
19
20 # attrs skipped
21 {
22 BEGIN { $^H{"t::parts/skip-attrs"} = 1; }
23
24 ok( !defined eval 'parts OTHERNAME :method { }; 1',
25 'func with attrs to parse when attrs skipped' );
26 }
27
28 done_testing;