Merge 'reorganize_tests' into 'DBIx-Class-current'
[dbsrgits/DBIx-Class.git] / t / run / 14mssql.tl
index 5dcc2bc..f21d9e2 100644 (file)
@@ -1,11 +1,15 @@
-sub run_tests {
-my $schema = shift;
+use strict;
+use warnings;  
+
+use Test::More;
+use lib qw(t/lib);
+use DBICTest;
 
 my ($dsn, $user, $pass) = @ENV{map { "DBICTEST_MSSQL_${_}" } qw/DSN USER PASS/};
 
 #warn "$dsn $user $pass";
 
-plan skip_all, 'Set $ENV{DBICTEST_MSSQL_DSN}, _USER and _PASS to run this test'
+plan skip_all => 'Set $ENV{DBICTEST_MSSQL_DSN}, _USER and _PASS to run this test'
   unless ($dsn);
 
 plan tests => 4;
@@ -38,11 +42,8 @@ my $it = MSSQLTest::Artist->search( { },
 );
 
 is( $it->count, 3, "LIMIT count ok" );
-is( $it->next->name, "Artist 2", "iterator->next ok" );
+ok( $it->next->name, "iterator->next ok" );
 $it->next;
 $it->next;
 is( $it->next, undef, "next past end of resultset ok" );
 
-}
-
-1;