[Bps-public-commit] r19022 - Shipwright/trunk/lib/Shipwright/Source

sunnavy at bestpractical.com sunnavy at bestpractical.com
Thu Apr 2 04:10:19 EDT 2009


Author: sunnavy
Date: Thu Apr  2 04:10:18 2009
New Revision: 19022

Modified:
   Shipwright/trunk/lib/Shipwright/Source/Base.pm

Log:
added test_requires support for Module::Install: it acts the same as build_requires actually

Modified: Shipwright/trunk/lib/Shipwright/Source/Base.pm
==============================================================================
--- Shipwright/trunk/lib/Shipwright/Source/Base.pm	(original)
+++ Shipwright/trunk/lib/Shipwright/Source/Base.pm	Thu Apr  2 04:10:18 2009
@@ -176,6 +176,8 @@
                 $makefile =~ s/^\s*requires(?!\w)/shipwright_requires/mg;
                 $makefile =~
                   s/^\s*build_requires(?!\w)/shipwright_build_requires/mg;
+                $makefile =~
+                  s/^\s*test_requires(?!\w)/shipwright_test_requires/mg;
                 $makefile =~ s/^\s*recommends(?!\w)/shipwright_recommends/mg;
                 $makefile =~ s/^\s*features(?!\w)/shipwright_features/mg;
                 $makefile =~ s/^\s*feature(?!\w)/shipwright_feature/mg;
@@ -200,6 +202,11 @@
     goto &build_requires;
 }
 
+sub shipwright_test_requires {
+    _shipwright_requires( 'build_requires', @_ == 1 ? ( @_, 0 ) : @_ );
+    goto &test_requires;
+}
+
 sub shipwright_recommends {
     _shipwright_requires( 'recommends', @_ == 1 ? ( @_, 0 ) : @_ );
     goto &recommends;



More information about the Bps-public-commit mailing list