},
},
- author => {
+
+ test_pod => {
req => {
'Test::Pod' => '1.41',
+ },
+ },
+
+ test_podcoverage => {
+ req => {
'Test::Pod::Coverage' => '1.08',
'Pod::Coverage' => '0.20',
+ },
+ },
+
+ test_notabs => {
+ req => {
#'Test::NoTabs' => '0.9',
+ },
+ },
+
+ test_eol => {
+ req => {
#'Test::EOL' => '0.6',
},
},
- core => {
+ test_cycle => {
req => {
- # t/52cycle.t
'Test::Memory::Cycle' => '0',
'Devel::Cycle' => '1.10',
+ },
+ },
+ test_dtrelated => {
+ req => {
# t/36datetime.t
# t/60core.t
'DateTime::Format::SQLite' => '0',
use lib qw(t/lib);
use DBICTest;
-my @MODULES = (
- 'Test::Pod 1.41',
-);
-
# Don't run tests for installs
unless ( DBICTest::AuthorCheck->is_author || $ENV{AUTOMATED_TESTING} || $ENV{RELEASE_TESTING} ) {
plan( skip_all => "Author tests not required for installation" );
}
-# Load the testing modules
-foreach my $MODULE ( @MODULES ) {
- eval "use $MODULE";
- if ( $@ ) {
- $ENV{RELEASE_TESTING}
- ? die( "Failed to load required release-testing module $MODULE" )
- : plan( skip_all => "$MODULE not available for testing" );
- }
+require DBIx::Class;
+unless ( DBIx::Class::Optional::Dependencies->req_ok_for ('test_pod') ) {
+ my $missing = DBIx::Class::Optional::Dependencies->req_missing_for ('test_pod');
+ $ENV{RELEASE_TESTING} || DBICTest::AuthorCheck->is_author
+ ? die ("Failed to load release-testing module requirements: $missing")
+ : plan skip_all => "Test needs: $missing"
}
-all_pod_files_ok();
+Test::Pod::all_pod_files_ok();
use lib qw(t/lib);
use DBICTest;
-my @MODULES = (
- 'Test::Pod::Coverage 1.08',
- 'Pod::Coverage 0.20',
-);
-
# Don't run tests for installs
unless ( DBICTest::AuthorCheck->is_author || $ENV{AUTOMATED_TESTING} || $ENV{RELEASE_TESTING} ) {
plan( skip_all => "Author tests not required for installation" );
}
-# Load the testing modules
-foreach my $MODULE ( @MODULES ) {
- eval "use $MODULE";
- if ( $@ ) {
- $ENV{RELEASE_TESTING}
- ? die( "Failed to load required release-testing module $MODULE" )
- : plan( skip_all => "$MODULE not available for testing" );
- }
+require DBIx::Class;
+unless ( DBIx::Class::Optional::Dependencies->req_ok_for ('test_podcoverage') ) {
+ my $missing = DBIx::Class::Optional::Dependencies->req_missing_for ('test_podcoverage');
+ $ENV{RELEASE_TESTING} || DBICTest::AuthorCheck->is_author
+ ? die ("Failed to load release-testing module requirements: $missing")
+ : plan skip_all => "Test needs: $missing"
}
# Since this is about checking documentation, a little documentation
if exists($ex->{ignore});
# run the test with the potentially modified parm set
- pod_coverage_ok($module, $parms, "$module POD coverage");
+ Test::Pod::Coverage::pod_coverage_ok($module, $parms, "$module POD coverage");
}
}
use lib qw(t/lib);
BEGIN {
- eval { require Test::Memory::Cycle; require Devel::Cycle };
- if ($@ or Devel::Cycle->VERSION < 1.10) {
- plan skip_all => "leak test needs Test::Memory::Cycle and Devel::Cycle >= 1.10";
- };
+ require DBIx::Class;
+ plan skip_all => 'Test needs: ' . DBIx::Class::Optional::Dependencies->req_missing_for ('test_cycle')
+ unless ( DBIx::Class::Optional::Dependencies->req_ok_for ('test_cycle') );
}
use DBICTest;