From: Dave Rolsky Date: Fri, 25 Dec 2009 16:01:41 +0000 (-0600) Subject: make all xt tests optional, require Test::More 0.88+ X-Git-Tag: 0.22~5 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=eb98d2ddaf2f2e01386719cd8fba9bb432bcd87a;p=gitmo%2FMooseX-Singleton.git make all xt tests optional, require Test::More 0.88+ --- diff --git a/Makefile.PL b/Makefile.PL index 934caa0..d30460a 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -8,7 +8,7 @@ all_from 'lib/MooseX/Singleton.pm'; requires 'Moose' => '0.82'; build_requires 'Scalar::Util'; -build_requires 'Test::More'; +build_requires 'Test::More' => '0.88'; build_requires 'Test::Exception'; license 'Perl'; diff --git a/xt/pod-spell.t b/xt/pod-spell.t index ca2739f..2f38ac2 100644 --- a/xt/pod-spell.t +++ b/xt/pod-spell.t @@ -1,7 +1,9 @@ use strict; use warnings; -use Test::Spelling; +use Test::More; +eval 'use Test::Spelling;'; +plan skip_all => "Test::Spelling required for testing POD spelling" if $@; my @stopwords; for () { @@ -12,7 +14,7 @@ for () { add_stopwords(@stopwords); set_spell_cmd('aspell list -l en'); -all_pod_files_spelling_ok; +all_pod_files_spelling_ok(); __DATA__ metaclass diff --git a/xt/version-numbers.t b/xt/version-numbers.t index d40c091..cdeaad4 100644 --- a/xt/version-numbers.t +++ b/xt/version-numbers.t @@ -1,10 +1,14 @@ use strict; use warnings; +use Test::More; + +eval <<'EOF'; use File::Find::Rule; use Module::Info; +EOF -use Test::More qw( no_plan ); +plan skip_all => 'File::Find::Rule and Module::Info required for testing version numbers' if $@; my %versions; @@ -22,3 +26,5 @@ for my $module ( grep { $_ ne 'MooseX/Singleton.pm' } sort keys %versions ) { is( $versions{$module}, $moose_ver, "version for $module is the same as in MooseX/Singleton.pm" ); } + +done_testing;