Revert 2c2bc4e5 - it is entirely superseded by cb551b07, 2baba3d9 and 83eef562
[dbsrgits/DBIx-Class.git] / t / lib / DBICTest.pm
index 49df060..aa20b0c 100644 (file)
@@ -5,7 +5,7 @@ use strict;
 use warnings;
 
 use DBICTest::Util 'local_umask';
-use DBICTest::RunMode;
+use DBICTest::Schema;
 use DBICTest::Util::LeakTracer qw/populate_weakregistry assert_empty_weakregistry/;
 use Carp;
 use Path::Class::File ();
@@ -314,8 +314,6 @@ sub init_schema {
 
     my $schema;
 
-    require DBICTest::Schema;
-
     if ($args{compose_connection}) {
       $schema = DBICTest::Schema->compose_connection(
                   'DBICTest', $self->_database(%args)
@@ -345,11 +343,7 @@ sub init_schema {
 }
 
 END {
-  # Make sure we run after any cleanup in other END blocks
-  require B;
-  push @{ B::end_av()->object_2svref }, sub {
     assert_empty_weakregistry($weak_registry, 'quiet');
-  };
 }
 
 =head2 deploy_schema
@@ -576,10 +570,4 @@ sub populate_schema {
     ]);
 }
 
-sub connect_schema {
-  my $self = shift;
-  require DBICTest::Schema;
-  return DBICTest::Schema->connect(@_);
-}
-
 1;