X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Funit_core_mvc.t;fp=t%2Funit_core_mvc.t;h=6d1c7fcc9a46a025c970ffa5d0e4ab4d60a399b9;hb=3fc0073c71b2590168ab0503100b475cb201a524;hp=f77e263f4d232aac0675a393611b0630788659fa;hpb=2105b371d738ee90655706e0953a30eb092ea04e;p=catagits%2FCatalyst-Runtime.git diff --git a/t/unit_core_mvc.t b/t/unit_core_mvc.t index f77e263..6d1c7fc 100644 --- a/t/unit_core_mvc.t +++ b/t/unit_core_mvc.t @@ -1,4 +1,4 @@ -use Test::More tests => 45; +use Test::More tests => 46; use strict; use warnings; @@ -158,6 +158,11 @@ is ( MyApp->model , 'MyApp::Model::M', 'default_model in class method ok'); my $c = bless {}, 'MyApp'; + # test accept-context with class rather than instance + MyApp->model('M', qw/foo bar/); + is_deeply($args, [qw/foo bar/], '$c->model args passed to ACCEPT_CONTEXT ok'); + + $c->model('M', qw/foo bar/); is_deeply($args, [qw/foo bar/], '$c->model args passed to ACCEPT_CONTEXT ok');