- remove borked tag again
[catagits/Catalyst-Runtime.git] / t / unit / core / mvc.t
CommitLineData
af3ff00e 1use Test::More tests => 7;
2use strict;
3use warnings;
4
5use_ok('Catalyst');
6
7my @complist =
8 map { "MyApp::$_"; }
9 qw/C::Controller M::Model V::View Controller::C Model::M View::V/;
10
11{
12
13 package MyApp;
14
15 use base qw/Catalyst/;
16
17 __PACKAGE__->components( { map { ( $_, $_ ) } @complist } );
18}
19
20is( MyApp->view('View'), 'MyApp::V::View', 'V::View ok' );
21
22is( MyApp->controller('Controller'),
23 'MyApp::C::Controller', 'C::Controller ok' );
24
25is( MyApp->model('Model'), 'MyApp::M::Model', 'M::Model ok' );
26
27is( MyApp->view('V'), 'MyApp::View::V', 'View::V ok' );
28
29is( MyApp->controller('C'), 'MyApp::Controller::C', 'Controller::C ok' );
30
31is( MyApp->model('M'), 'MyApp::Model::M', 'Model::M ok' );