Don't run the moose controller test if Moose isn't available
[catagits/Catalyst-Runtime.git] / t / live_component_controller_moose.t
CommitLineData
b68b4c7c 1use strict;
2use warnings;
e16a6c4e 3use Test::More;
4
5BEGIN {
6 if (eval 'require Moose; 1') {
7 plan tests => 2;
8 }
9 else {
10 plan skip_all => 'Moose is required for this test';
11 }
12}
b68b4c7c 13
14use FindBin;
15use lib "$FindBin::Bin/lib";
16
b68b4c7c 17use Catalyst::Test 'TestApp';
18
19{
20 my $response = request('http://localhost/moose/get_attribute');
21 ok($response->is_success);
22 is($response->content, '42', 'attribute default values get set correctly');
23}