remove a submodule from travis
[catagits/Catalyst-Runtime.git] / t / accept_context_regression.t
1 use strict;
2 use warnings;
3 use Test::More;
4
5 {
6   package MyApp::Model::AcceptContext;
7   use base 'Catalyst::Model';
8
9   sub ACCEPT_CONTEXT {
10     my ($self, $c, @args) = @_;
11     Test::More::ok( ref $c);
12   }
13
14   $INC{'MyApp/Model/AcceptContext.pm'} = __FILE__;
15
16   package MyApp::Controller::Root;
17   use base 'Catalyst::Controller';
18
19   sub test_model :Local {
20     my ($self, $c) = @_;
21     $c->res->body('test');
22   }
23
24   $INC{'MyApp/Controller/Root.pm'} = __FILE__;
25
26   package MyApp;
27   use Catalyst;
28   
29   MyApp->setup;
30 }
31
32 use Catalyst::Test 'MyApp';
33
34 my ($res, $c) = ctx_request('/test_model');
35
36 ok $res;
37
38
39 done_testing;
40