warn about missing shells specified on the command line
Graham Knop [Thu, 2 Jan 2014 02:02:26 +0000 (21:02 -0500)]
t/shell.t

index 0d5ce61..54f9251 100644 (file)
--- a/t/shell.t
+++ b/t/shell.t
@@ -47,11 +47,20 @@ for my $shell (
   },
 ) {
   my $name = $shell->{name};
-  next
-    if @ARGV && !grep {$_ eq $name} @ARGV;
-  $shell->{shell} = which($name) || next;
+  $shell->{shell} = which($name);
   $shell->{ext}   ||= $name;
   $shell->{perl}  ||= qq{"$^X"};
+  if (@ARGV) {
+    next
+      if !grep {$_ eq $name} @ARGV;
+    if (!$shell->{shell}) {
+      warn "unable to find executable for $name";
+      next;
+    }
+  }
+  elsif (!$shell->{shell}) {
+    next;
+  }
   push @shells, $shell;
 }