[Bps-public-commit] r10131 - in Test-Dependencies/trunk: lib/Test

zev at bestpractical.com zev at bestpractical.com
Wed Dec 26 22:56:29 EST 2007


Author: zev
Date: Wed Dec 26 22:56:28 2007
New Revision: 10131

Modified:
   Test-Dependencies/trunk/   (props changed)
   Test-Dependencies/trunk/lib/Test/Dependencies.pm

Log:
 r10354 at cliffjumper:  zev | 2007-12-26 19:40:41 -0500
 * don't complain if specified dependencies are in core


Modified: Test-Dependencies/trunk/lib/Test/Dependencies.pm
==============================================================================
--- Test-Dependencies/trunk/lib/Test/Dependencies.pm	(original)
+++ Test-Dependencies/trunk/lib/Test/Dependencies.pm	Wed Dec 26 22:56:28 2007
@@ -113,7 +113,6 @@
   my $perl = $^X;
   my %deps;
   foreach my $file (sort @sourcefiles) {
-    print "# source file $file\n";
     my $taint = _taint_flag($file);
     my ($success, $error_code, $full_buf, $stdout_buf, $stderr_buf) =
       run(command => [$perl, $taint, '-MO=PerlReq', $file]);
@@ -177,13 +176,12 @@
   my %required = exists $meta->{requires} && defined $meta->{requires} ? %{$meta->{requires}} : ();
   my %build_required = exists $meta->{build_requires} ? %{$meta->{build_requires}} : ();
 
-  my @in_core;
-  
   foreach my $mod (sort keys %used) {
     my $first_in = Module::CoreList->first_release($mod);
     if (defined $first_in and $first_in <= 5.00803) {
+      $tb->ok(1, "run-time dependency '$mod' has been in core since before 5.8.3");
       delete $used{$mod};
-      push @in_core, $mod if exists $required{$mod};
+      delete $required{$mod};
       next;
     }
     if (defined $exclude_re && $mod =~ m/^($exclude_re)(::|$)/) {
@@ -198,8 +196,9 @@
   foreach my $mod (sort keys %build_used) {
     my $first_in = Module::CoreList->first_release($mod);
     if (defined $first_in and $first_in <= 5.00803) {
+      $tb->ok(1, "build-time dependency '$mod' has been in core since before 5.8.3");
       delete $build_used{$mod};
-      push @in_core, $mod if exists $build_required{$mod};
+      delete $build_required{$mod};
       next;
     }
     if (defined $exclude_re && $mod =~ m/^($exclude_re)(::|$)/) {
@@ -211,10 +210,6 @@
     delete $build_required{$mod};
   }  
 
-  foreach my $mod (sort @in_core) {
-    $tb->ok(0, "Required module $mod is in core");
-  }
-  
   foreach my $mod (sort keys %required) {
     $tb->ok(0, "$mod is not a run-time dependency");
   }



More information about the Bps-public-commit mailing list