Reverting a48693f42e - the test is a fat duplicate of t/prefetch/false_colvalues.t
[dbsrgits/DBIx-Class.git] / t / storage / replicated.t
index dc77f0b..c8d469f 100644 (file)
@@ -3,14 +3,15 @@ use warnings;
 
 use Test::More;
 
+use lib qw(t/lib);
+use DBICTest;
+
 BEGIN {
     require DBIx::Class;
     plan skip_all => 'Test needs ' . DBIx::Class::Optional::Dependencies->req_missing_for ('test_replicated')
       unless DBIx::Class::Optional::Dependencies->req_ok_for ('test_replicated');
 }
 
-use lib qw(t/lib);
-use DBICTest;
 
 if (DBICTest::RunMode->is_smoker) {
   my $mver = Moose->VERSION;
@@ -78,15 +79,8 @@ TESTSCHEMACLASSES: {
     ## Get the Schema and set the replication storage type
 
     sub init_schema {
-        # current SQLT SQLite producer does not handle DROP TABLE IF EXISTS, trap warnings here
-        local $SIG{__WARN__} = sub { warn @_ unless $_[0] =~ /no such table.+DROP TABLE/s };
-
-        my ($class, $schema_method) = @_;
-
-        my $method = "get_schema_$schema_method";
-        my $schema = $class->$method;
-
-        return $schema;
+        #my ($class, $schema_getter) = @_;
+        shift->${\ ( 'get_schema_' . shift ) };
     }
 
     sub get_schema_by_storage_type {