[Jifty-commit] r985 - in jifty/trunk: t

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Thu May 4 00:10:37 EDT 2006


Author: ewilhelm
Date: Thu May  4 00:10:34 2006
New Revision: 985

Modified:
   jifty/trunk/   (props changed)
   jifty/trunk/t/01-version_checks.t

Log:
 r919 at mjolnir:  ewilhelm | 2006-05-03 21:07:40 -0700
 t/01-version_checks.t - fixed to run under test harness


Modified: jifty/trunk/t/01-version_checks.t
==============================================================================
--- jifty/trunk/t/01-version_checks.t	(original)
+++ jifty/trunk/t/01-version_checks.t	Thu May  4 00:10:34 2006
@@ -2,9 +2,21 @@
 use strict;
 use Test::More qw(no_plan);
 
+# by Eric Wilhelm in response to Randal Schwartz pointing out that
+# CPAN.pm chokes on the VERSION >... construct
+# I dare not mention it here.
+
 use ExtUtils::MakeMaker;
 use_ok('Jifty::Everything');
-my @files = grep({$_ !~ m#^/#} map({$INC{$_}} grep(/^Jifty\//, keys(%INC))));
+
+# XXX there may be a more cross-platform and harness-friendly way to say
+# this.  Tricky bit is that the harness absolutifies the lib paths or
+# plans to chdir() somewhere.
+
+# just look for Jifty.pm
+my $dir = $INC{'Jifty.pm'};
+$dir =~ s/Jifty\.pm$//;
+my @files = grep({$_ =~ m/^$dir/} map({$INC{$_}} grep(/^Jifty\//, keys(%INC))));
 ok(scalar(@files));
 
 foreach my $file (@files) {


More information about the Jifty-commit mailing list