From: jocuri%softhome.net <> Date: Tue, 7 Dec 2004 01:02:44 +0000 (+0000) Subject: Patch for bug 258579: t/Support/Files.pm should use File::Find; patch by Marc Schuman... X-Git-Tag: bugzilla-2.18~81 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f39dc2007a7e318d66446997ac56dbfc6720c05f;p=thirdparty%2Fbugzilla.git Patch for bug 258579: t/Support/Files.pm should use File::Find; patch by Marc Schumann , r=vladd, a=justdave. --- diff --git a/t/Support/Files.pm b/t/Support/Files.pm index ffadc562c4..2e62020421 100644 --- a/t/Support/Files.pm +++ b/t/Support/Files.pm @@ -23,6 +23,8 @@ package Support::Files; +use File::Find; + # exclude_deps is a hash of arrays listing the files to be excluded # if a module is not available # @@ -33,10 +35,8 @@ package Support::Files; ); -# XXX - this file should really be rewritten to use File::Find or similar -$file = '*'; -@files = (glob($file), glob('Bugzilla/*.pm'), glob('Bugzilla/*/*.pm'), - glob('Bugzilla/*/*/*.pm')); +@files = glob('*'); +find(sub { push(@files, $File::Find::name) if $_ =~ /\.pm$/;}, 'Bugzilla'); sub have_pkg { my ($pkg) = @_;