X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2F10-live_auto.t;h=782bf7da05c62be68074c1d3cc14a82cf41e23db;hb=64fa55fd5956658cf77b4d7142df46707a968c20;hp=8420c272156eac62ce3bd7cae6d1dc5e24e366b9;hpb=a7afecf726304cbb5556cd5d93ad823e0ac4945f;p=catagits%2FCatalyst-Plugin-ConfigLoader.git diff --git a/t/10-live_auto.t b/t/10-live_auto.t index 8420c27..782bf7d 100644 --- a/t/10-live_auto.t +++ b/t/10-live_auto.t @@ -4,18 +4,27 @@ use warnings; use FindBin; use lib "$FindBin::Bin/lib"; -use Test::More tests => 4; +use Test::More tests => 5; use Catalyst::Test 'TestApp'; { my $response; - ok( $response = request('http://localhost/config/'), 'request ok' ); + ok( $response = request( 'http://localhost/config/' ), 'request ok' ); is( $response->content, 'foo', 'config ok' ); - $response = request('http://localhost/appconfig/cache'); - ok( $response->content !~ /^__HOME__/, 'home dir substituted in config var' ); + $response = request( 'http://localhost/appconfig/cache' ); + ok( $response->content !~ /^__HOME__/, + 'home dir substituted in config var' + ); - $response = request('http://localhost/appconfig/foo'); + $response = request( 'http://localhost/appconfig/foo' ); is( $response->content, 'bar', 'app finalize_config works' ); + + $response = request( 'http://localhost/appconfig/multi' ); + my $home = TestApp->config->{ home }; + my $path = join( ',', + $home, TestApp->path_to( 'x' ), + $home, TestApp->path_to( 'y' ) ); + is( $response->content, $path, 'vars substituted in config var, twice' ); }