Centralize remaining uses of Sub::Name within _Util
[dbsrgits/DBIx-Class.git] / t / icdt / engine_specific / sqlanywhere.t
index f186f93..00e9d56 100644 (file)
@@ -1,11 +1,12 @@
+BEGIN { do "./t/lib/ANFANG.pm" or die ( $@ || $! ) }
 use DBIx::Class::Optional::Dependencies -skip_all_without => qw( ic_dt _rdbms_sqlanywhere_common );
 
 use strict;
 use warnings;
 
 use Test::More;
-use Scope::Guard ();
-use lib qw(t/lib);
+use DBIx::Class::_Util 'scope_guard';
+
 use DBICTest;
 
 my @tdeps = qw( test_rdbms_sqlanywhere test_rdbms_sqlanywhere_odbc );
@@ -38,7 +39,7 @@ foreach my $info (@info) {
     on_connect_call => 'datetime_setup',
   });
 
-  my $sg = Scope::Guard->new(sub { cleanup($schema) } );
+  my $sg = scope_guard { cleanup($schema) };
 
   eval { $schema->storage->dbh->do('DROP TABLE event') };
   $schema->storage->dbh->do(<<"SQL");