From: Dagfinn Ilmari Mannsåker <ilmari@ilmari.org>
Date: Fri, 9 Nov 2007 16:41:45 +0000 (+0000)
Subject: Fix Win32 test skip counts for good (RT #30568, Kenichi Ishigaki)
X-Git-Tag: 0.04004~1
X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=2ffd6b4c76d2ff288dff843d6e2689b791f881a2;p=dbsrgits%2FDBIx-Class-Schema-Loader.git

Fix Win32 test skip counts for good (RT #30568, Kenichi Ishigaki)
---

diff --git a/Changes b/Changes
index 06ac9dd..607842f 100644
--- a/Changes
+++ b/Changes
@@ -1,5 +1,6 @@
 Revision history for Perl extension DBIx::Class::Schema::Loader
 
+        - Fix Win32 test skip counts for good (RT #30568, Kenichi Ishigaki)
         - Default Oracle db_schema to db username (patch
           from Johannes Plunien)
 
diff --git a/t/22dump.t b/t/22dump.t
index cdb0f50..a10c483 100644
--- a/t/22dump.t
+++ b/t/22dump.t
@@ -33,7 +33,12 @@ ok(!$@, 'no death with dump_directory set') or diag "Dump failed: $@";
 DBICTest::Schema::1->_loader_invoked(undef);
 
 SKIP: {
-  skip "ActiveState perl produces additional warnings", 3
+  my @warnings_regexes = (
+      qr|Dumping manual schema|,
+      qr|Schema dump completed|,
+  );
+
+  skip "ActiveState perl produces additional warnings", scalar @warnings_regexes
     if ($^O eq 'MSWin32');
 
   my @warn_output;
@@ -41,10 +46,6 @@ SKIP: {
       local $SIG{__WARN__} = sub { push(@warn_output, @_) };
       DBICTest::Schema::1->connect($make_dbictest_db::dsn);
   }
-  my @warnings_regexes = (
-      qr|Dumping manual schema|,
-      qr|Schema dump completed|,
-  );
 
   like(shift @warn_output, $_) foreach (@warnings_regexes);