Only load DBICTest::Schema when needed in tests
[dbsrgits/DBIx-Class.git] / t / zzzzzzz_sqlite_deadlock.t
index 6a38d2c..4aa2030 100644 (file)
@@ -4,14 +4,15 @@ use warnings;
 use Test::More;
 
 use lib 't/lib';
-use DBICTest::RunMode;
-
-if ( DBICTest::RunMode->is_plain ) {
-  plan( skip_all => "Skipping test on plain module install" );
+BEGIN {
+  require DBICTest::RunMode;
+  plan( skip_all => "Skipping test on plain module install" )
+    if DBICTest::RunMode->is_plain;
 }
 
 use Test::Exception;
 use DBICTest;
+use DBICTest::Schema;
 use File::Temp ();
 
 plan tests => 2;