From 9940ceb7c772129cfe7eb17545e3c7bbca73cf9e Mon Sep 17 00:00:00 2001 From: Graham Knop Date: Mon, 15 Sep 2008 21:51:36 +0000 Subject: [PATCH] also check syntax of utility scripts and upgrades --- t/syntaxCheck.t | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/t/syntaxCheck.t b/t/syntaxCheck.t index fb12abfbd..2a605c188 100644 --- a/t/syntaxCheck.t +++ b/t/syntaxCheck.t @@ -16,13 +16,15 @@ use WebGUI::Test; use File::Find; use WebGUI::Session; use Test::More; +use File::Spec; plan skip_all => 'set TEST_SYNTAX to enable this test' unless $ENV{TEST_SYNTAX}; my @modules; my $wgLib = WebGUI::Test->lib; +my $wgRoot = WebGUI::Test->root; #diag("Checking modules in $wgLib"); -File::Find::find( \&getWebGUIModules, $wgLib); +File::Find::find( \&getWebGUIModules, $wgLib, File::Spec->join($wgRoot, 'sbin'), File::Spec->join($wgRoot, 'docs', 'upgrades') ); my $numTests = scalar @modules; @@ -38,5 +40,5 @@ foreach my $package (@modules) { #---------------------------------------- sub getWebGUIModules { - push( @modules, $File::Find::name ) if /\.pm$/; + push( @modules, $File::Find::name ) if /\.p[ml]$/; }