From: Jonathan Yu Date: Sun, 10 Jan 2010 05:04:57 +0000 (-0500) Subject: eval require instead of use X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=fb4fa0d12be8f2b08154651246dd22b27e6c456b;p=gitmo%2FMooseX-Storage.git eval require instead of use We need to eval require instead of use to prevent double imports, since loading YAML::Any causes symbols to be exported by default --- diff --git a/t/020_basic_yaml.t b/t/020_basic_yaml.t index a3c0e03..9f60bf9 100644 --- a/t/020_basic_yaml.t +++ b/t/020_basic_yaml.t @@ -8,7 +8,7 @@ use Test::More; BEGIN { eval "use YAML::Any"; plan skip_all => "YAML::Any is required for this test" if $@; - eval "use YAML"; + eval "require YAML"; plan skip_all => "YAML is required for this test" if $@; eval "require Test::Without::Module"; plan skip_all => "Test::Without::Module is required for this test" if $@; diff --git a/t/020_basic_yaml_syck.t b/t/020_basic_yaml_syck.t index 8def928..d94fcd2 100644 --- a/t/020_basic_yaml_syck.t +++ b/t/020_basic_yaml_syck.t @@ -8,7 +8,7 @@ use Test::More; BEGIN { eval "use YAML::Any"; plan skip_all => "YAML::Any is required for this test" if $@; - eval "use YAML::Syck"; + eval "require YAML::Syck"; plan skip_all => "YAML::Syck is required for this test" if $@; eval "require Test::Without::Module"; plan skip_all => "Test::Without::Module is required for this test" if $@; diff --git a/t/020_basic_yaml_xs.t b/t/020_basic_yaml_xs.t index 8650a0e..42d1d07 100644 --- a/t/020_basic_yaml_xs.t +++ b/t/020_basic_yaml_xs.t @@ -8,7 +8,7 @@ use Test::More; BEGIN { eval "use YAML::Any"; plan skip_all => "YAML::Any is required for this test" if $@; - eval "use YAML::XS"; + eval "require YAML::XS"; plan skip_all => "YAML::XS is required for this test" if $@; eval "require Test::Without::Module"; plan skip_all => "Test::Without::Module is required for this test" if $@;