updated changes and makefile.pl for release
[p5sagit/Config-Any.git] / t / 55-yaml.t
index 74ff1b1..3c95831 100644 (file)
@@ -1,11 +1,18 @@
-use Test::More tests => 2;\r
-\r
-use Config::Any::YAML;\r
-\r
-my $config = eval { Config::Any::YAML->load( 't/conf/conf.yml' ) };\r
-\r
-SKIP: {\r
-    skip "Couldn't Load YAML plugin", 2 if $@;\r
-    ok( $config );\r
-    is( $config->{ name }, 'TestApp' );\r
-}\r
+use strict;
+use warnings;
+
+use Test::More;
+use Config::Any::YAML;
+
+if ( !Config::Any::YAML->is_supported ) {
+    plan skip_all => 'YAML format not supported';
+}
+else {
+    plan tests => 2;
+}
+
+{
+    my $config = Config::Any::YAML->load( 't/conf/conf.yml' );
+    ok( $config );
+    is( $config->{ name }, 'TestApp' );
+}