More actions moved to root controllers.
[catagits/Catalyst-Runtime.git] / t / lib / PluginTestApp.pm
1 package PluginTestApp;
2 use Test::More;
3
4 use Catalyst qw(
5         Test::Plugin
6         +TestApp::Plugin::FullyQualified
7         );
8
9 sub _test_plugins {
10     my $c = shift;
11     is_deeply [ $c->registered_plugins ],
12     [
13         qw/Catalyst::Plugin::Test::Plugin
14         TestApp::Plugin::FullyQualified/
15         ],
16     '... and it should report the correct plugins';
17     ok $c->registered_plugins('Catalyst::Plugin::Test::Plugin'),
18     '... or if we have a particular plugin';
19     ok $c->registered_plugins('Test::Plugin'),
20     '... even if it is not fully qualified';
21     ok !$c->registered_plugins('No::Such::Plugin'),
22     '... and it should return false if the plugin does not exist';
23 }
24
25 __PACKAGE__->setup;