my ($dsn, $user, $pass) = @ENV{map { "DBICTEST_ORA_${_}" } qw/DSN USER PASS/};
-eval "use DateTime; use DateTime::Format::Oracle;";
-if ($@) {
- plan skip_all => 'needs DateTime and DateTime::Format::Oracle for testing';
-}
-elsif (not ($dsn && $user && $pass)) {
+if (not ($dsn && $user && $pass)) {
plan skip_all => 'Set $ENV{DBICTEST_ORA_DSN}, _USER and _PASS to run this test. ' .
'Warning: This test drops and creates a table called \'track\'';
}
else {
- plan tests => 4;
+ eval "use DateTime; use DateTime::Format::Oracle;";
+ if ($@) {
+ plan skip_all => 'needs DateTime and DateTime::Format::Oracle for testing';
+ }
+ else {
+ plan tests => 4;
+ }
}
# DateTime::Format::Oracle needs this set
use Test::More;
BEGIN {
+ eval "use DBIx::Class::CDBICompat;";
+ if ($@) {
+ plan (skip_all => "Class::Trigger and DBIx::ContextualFetch required: $@");
+ next;
+ }
+
plan skip_all => 'needs DBD::SQLite for testing'
unless eval { require DBD::SQLite };
use Test::More;
+eval "use DBIx::Class::CDBICompat;";
+if ($@) {
+ plan (skip_all => "Class::Trigger and DBIx::ContextualFetch required: $@");
+ next;
+}
+
eval { require Time::Piece::MySQL };
plan skip_all => "Need Time::Piece::MySQL for this test" if $@;