Institute a central "load this first in testing" package
[dbsrgits/DBIx-Class-Historic.git] / t / search / subquery.t
index a281fe9..8b785e4 100644 (file)
@@ -1,12 +1,14 @@
+BEGIN { do "./t/lib/ANFANG.pm" or die ( $@ || $! ) }
+
 use strict;
 use warnings;
 
 use Test::More;
 
-use lib qw(t/lib);
-use DBICTest;
-use DBIC::SqlMakerTest;
+
+use DBICTest ':DiffSQL';
 use DBIx::Class::SQLMaker::LimitDialects;
+use DBIx::Class::_Util 'sigwarn_silencer';
 
 my $ROWS = DBIx::Class::SQLMaker::LimitDialects->__rows_bindtype;
 
@@ -165,6 +167,8 @@ my @tests = (
 for my $i (0 .. $#tests) {
   my $t = $tests[$i];
   for my $p (1, 2) {  # repeat everything twice, make sure we do not clobber search arguments
+    local $SIG{__WARN__} = sigwarn_silencer( qr/\Q{from} structures with conditions not conforming to the SQL::Abstract syntax are deprecated/ );
+
     is_same_sql_bind (
       $t->{rs}->search ($t->{search}, $t->{attrs})->as_query,
       $t->{sqlbind},