use_namespaces is now default, still needs the upgrade code
[dbsrgits/DBIx-Class-Schema-Loader.git] / t / backcompat / 0.04006 / 22dump.t
index 5aa5f59..9a53f7d 100644 (file)
@@ -3,13 +3,17 @@ use Test::More;
 use lib qw(t/backcompat/0.04006/lib);
 use File::Path;
 use make_dbictest_db;
-use Test::More;
-plan skip_all => 'Backcompat tests disabled'
-    unless $ENV{SCHEMA_LOADER_TESTS_BACKCOMPAT};
 
+plan skip_all => 'set SCHEMA_LOADER_TESTS_BACKCOMPAT to enable these tests'
+    unless $ENV{SCHEMA_LOADER_TESTS_BACKCOMPAT};
 
 my $dump_path = './t/_dump';
 
+local $SIG{__WARN__} = sub {
+    warn @_ unless $_[0] =~
+        /^Dumping manual schema|really_erase_my_files|^Schema dump complete/;
+};
+
 {
     package DBICTest::Schema::1;
     use base qw/ DBIx::Class::Schema::Loader /;
@@ -65,4 +69,4 @@ eval { DBICTest::Schema::2->connect($make_dbictest_db::dsn) };
 ok(!$@, 'no death with dump_directory set (overwrite2)')
     or diag "Dump failed: $@";
 
-END { rmtree($dump_path, 1, 1); }
+END { rmtree($dump_path, 1, 1) if $ENV{SCHEMA_LOADER_TESTS_BACKCOMPAT}; }