Fix spelling test failures
[catagits/Catalyst-Runtime.git] / t / dead_load_multiple_chained_attributes.t
1 use strict;
2 use warnings;
3 use lib 't/lib';
4
5 use Test::More;
6
7 plan tests => 4;
8
9 use Catalyst::Test 'TestApp';
10
11 eval q{
12     package TestApp::Controller::Action::Chained;
13     sub should_fail : Chained('/') Chained('foo') Args(0) {}
14 };
15 ok(!$@);
16
17 eval { TestApp->setup_actions; };
18 ok($@, 'Multiple chained attributes make action setup fail');
19
20 eval q{
21     package TestApp::Controller::Action::Chained;
22     no warnings 'redefine';
23     sub should_fail {}
24 };
25 ok(!$@);
26
27 eval { TestApp->setup_actions };
28 ok(!$@, 'And ok again') or warn $@;
29