Move Module::Pluggable from ext/ to cpan/
[p5sagit/p5-mst-13.2.git] / cpan / Module-Pluggable / t / 06multipath.t
CommitLineData
3f7169a2 1#!perl -w
2
3use strict;
4use FindBin;
183ac38d 5use lib (($FindBin::Bin."/lib")=~/^(.*)$/);
3f7169a2 6use Test::More tests => 3;
7
8
9my $foo;
10ok($foo = MyTest->new());
11
12my @plugins;
13my @expected = qw(Acme::MyTest::Plugin::Foo MyTest::Extend::Plugin::Bar);
14ok(@plugins = sort $foo->plugins);
15
16is_deeply(\@plugins, \@expected);
17
18
19
20package MyTest;
21use File::Spec::Functions qw(catdir);
22use strict;
23use File::Spec::Functions qw(catdir);
24use Module::Pluggable (search_path => ["MyTest::Extend::Plugin", "Acme::MyTest::Plugin"]);
25
26
27sub new {
28 my $class = shift;
29 return bless {}, $class;
30
31}
321;
33