Blob Blame History Raw
--- t/02-basic.t.orig	2009-04-27 22:32:51.000000000 +0200
+++ t/02-basic.t	2009-04-27 22:33:26.000000000 +0200
@@ -242,7 +242,10 @@
         ok $w->save, "Saving bad_wine $name";
     }
     # note sqlite is stupid and doesn't return the number of affected rows
-    is (Wine->remove({}, { nofetch => 1 }), '0E0', 'removing all bad wine');
+    # quick hack because I can't rely on version.pm to be installed everywhere
+    my ($sqlite_version) = Wine->driver->rw_handle->{sqlite_version} =~ /(\d+(?:\.\d+))/;
+    my $count = $sqlite_version > 3.5 ? scalar @bad_wines : "0E0";
+    is (Wine->remove({}, { nofetch => 1 }), $count, 'removing all bad wine');
 }
 
 # different utilities