Skip to content

Commit

Permalink
Add a version check to the plackup locator
Browse files Browse the repository at this point in the history
  • Loading branch information
stash committed Apr 9, 2011
1 parent fd00b9d commit 6cab347
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion t/62-plack-runner.t
Expand Up @@ -42,10 +42,18 @@ for my $dir (@Config{qw(sitebin sitescript vendbin vendscript)}) {
my $pu = "$dir/plackup";
if (-e $pu && -x _) {
$plackup = $pu;
diag "plackup: $plackup";
my $plackup_ver = `$^X $plackup --version`;
chomp $plackup_ver;
if ($plackup_ver =~ /Plack (\d.\d+)/ && $1 >= 0.995) {
diag "plackup: $plackup ($plackup_ver)";
}
else {
next;
}
last;
}
}

SKIP: {
skip "can't locate plackup in sitebin/sitescript/vendbin/vendscript", 2
unless $plackup;
Expand Down

0 comments on commit 6cab347

Please sign in to comment.