Commit | Line | Data |
e4cc83b2 |
1 | use strict; |
2 | use warnings; |
3 | |
4 | use FindBin; |
9c8b81a2 |
5 | use lib "$FindBin::Bin/../lib"; |
e4cc83b2 |
6 | |
7 | use Test::More tests => 9; |
8 | use Catalyst::Test 'TestApp'; |
9 | |
10 | my $expected = { |
11 | one => "foo", |
12 | two => "foobar", |
fe3083a8 |
13 | three => "foo,bar,baz:", |
e4cc83b2 |
14 | }; |
15 | |
1e6db81d |
16 | for my $action ( sort keys %{$expected} ) { |
e4cc83b2 |
17 | ok( my $response = request('http://localhost/engine/response/print/' . $action ), |
18 | 'Request' ); |
19 | ok( $response->is_success, "Response $action successful 2xx" ); |
20 | |
21 | is( $response->content, $expected->{$action}, "Content $action OK" ); |
22 | } |