use warnings;
use DBICTest::Util 'local_umask';
-use DBICTest::Schema;
+use DBICTest::RunMode;
use DBICTest::Util::LeakTracer qw/populate_weakregistry assert_empty_weakregistry/;
use Carp;
use Path::Class::File ();
my $schema;
+ require DBICTest::Schema;
+
if ($args{compose_connection}) {
$schema = DBICTest::Schema->compose_connection(
'DBICTest', $self->_database(%args)
}
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
]);
}
+sub connect_schema {
+ my $self = shift;
+ require DBICTest::Schema;
+ return DBICTest::Schema->connect(@_);
+}
+
1;