X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fstorage%2Freplicated.t;h=c8d469fd6e4813ec5bce014218964b70bfc1403a;hb=e327f12657df75fbc8d771b4b8d4495cf1dcbd79;hp=dc77f0b9f08c1fcb1710791f94fa816a6168d4a0;hpb=e4ee58613571bad55096510fa24608ded39f4e63;p=dbsrgits%2FDBIx-Class.git diff --git a/t/storage/replicated.t b/t/storage/replicated.t index dc77f0b..c8d469f 100644 --- a/t/storage/replicated.t +++ b/t/storage/replicated.t @@ -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 {