projects
/
gitmo/Moo.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
5f10e28844b1192ef7848779e91559338c38881f
[gitmo/Moo.git]
/
t
/
use-after-no.t
1
use strictures 1;
2
use Test::More;
3
4
ok eval q{
5
package Spoon;
6
use Moo;
7
8
has foo => ( is => 'ro' );
9
10
no Moo;
11
12
use Moo;
13
14
has foo2 => ( is => 'ro' );
15
16
no Moo;
17
18
1;
19
}, "subs imported on 'use Moo;' after 'no Moo;'"
20
or diag $@;
21
22
ok eval q{
23
package Roller;
24
use Moo::Role;
25
26
has foo => ( is => 'ro' );
27
28
no Moo::Role;
29
30
use Moo::Role;
31
32
has foo2 => ( is => 'ro' );
33
34
no Moo::Role;
35
36
1;
37
}, "subs imported on 'use Moo::Role;' after 'no Moo::Role;'"
38
or diag $@;
39
40
done_testing;