This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Add Module::Pluggable
[perl5.git] / lib / Module / Pluggable / t / 10innerpack_inner.t
CommitLineData
3f7169a2
RGS
1#!perl -w
2
3use strict;
4use FindBin;
5use lib "$FindBin::Bin/lib";
6use Test::More tests => 3;
7
8
9
10my $t = InnerTest->new();
11
12my %plugins = map { $_ => 1 } $t->plugins;
13
14ok(keys %plugins, "Got some plugins");
15ok($plugins{'InnerTest::Plugin::Foo'}, "Got Foo");
16ok($plugins{'InnerTest::Plugin::Bar'}, "Got Bar - the inner package");
17
18
19
20package InnerTest;
21use strict;
22use Module::Pluggable inner => 1;
23use base qw(Module::Pluggable);
24
25
26sub new {
27 my $class = shift;
28 return bless {}, $class;
29
30}
31
32
331;
34