Move tests under 'threads' module
[p5sagit/p5-mst-13.2.git] / t / Module_Pluggable / 02alsoworks.t
CommitLineData
3f7169a2 1#!perl -w
2
3use strict;
4use FindBin;
5use lib "$FindBin::Bin/lib";
6use Test::More tests => 5;
7
8my $foo;
9ok($foo = MyOtherTest->new());
10
11my @plugins;
12my @expected = qw(MyOtherTest::Plugin::Bar MyOtherTest::Plugin::Foo MyOtherTest::Plugin::Quux MyOtherTest::Plugin::Quux::Foo);
13ok(@plugins = sort $foo->plugins);
14
15
16
17is_deeply(\@plugins, \@expected, "is deeply");
18
19@plugins = ();
20
21ok(@plugins = sort MyOtherTest->plugins);
22
23
24
25
26is_deeply(\@plugins, \@expected, "is deeply class");
27
28
29
30package MyOtherTest;
31
32use strict;
33use Module::Pluggable;
34
35
36sub new {
37 my $class = shift;
38 return bless {}, $class;
39
40}
411;
42