X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FConfig-Any.git;a=blobdiff_plain;f=t%2F52-json.t;h=5467ebe6c7e4d6da38434fd737eb73d27adbcb90;hp=dcf084f13a78ea4d59453dc908ed27bbdf0bec40;hb=5a2e0210fe5c7da046be37b4240008f2b667be67;hpb=f103b82bc783be531637c754c37783aa6c144a45 diff --git a/t/52-json.t b/t/52-json.t index dcf084f..5467ebe 100644 --- a/t/52-json.t +++ b/t/52-json.t @@ -1,11 +1,18 @@ -use Test::More tests => 2; +use strict; +use warnings; +use Test::More; use Config::Any::JSON; -my $config = eval { Config::Any::JSON->load( 't/conf/conf.json' ) }; +if ( !Config::Any::JSON->is_supported ) { + plan skip_all => 'JSON format not supported'; +} +else { + plan tests => 2; +} -SKIP: { - skip "Couldn't Load JSON plugin", 2 if $@; +{ + my $config = Config::Any::JSON->load( 't/conf/conf.json' ); ok( $config ); is( $config->{ name }, 'TestApp' ); }