Find it attached, not functionality has been changed, just cleanup.

consider doing a chmod +x *.pl to make the perl scripts executable

--
Stefano.

Index: TErrorsReport.pl
===================================================================
RCS file: /home/cvspublic/jakarta-slide/testsuite/bin/TErrorsReport.pl,v
retrieving revision 1.1
diff -u -r1.1 TErrorsReport.pl
--- TErrorsReport.pl    16 Jul 2003 07:08:48 -0000      1.1
+++ TErrorsReport.pl    26 Nov 2003 15:05:35 -0000
@@ -1,3 +1,5 @@
+#!/usr/bin/perl
+
 # Set defaults
 # NOTE: (1) TP_HOME=.. works if tprocessor.cmd is started from the bin directory.
 #           Otherwise, set TP_HOME to point to the TProcessor installation directory, 
or use 
Index: TProcessor.pl
===================================================================
RCS file: /home/cvspublic/jakarta-slide/testsuite/bin/TProcessor.pl,v
retrieving revision 1.2
diff -u -r1.2 TProcessor.pl
--- TProcessor.pl       11 Aug 2003 14:51:15 -0000      1.2
+++ TProcessor.pl       26 Nov 2003 15:05:36 -0000
@@ -1,3 +1,5 @@
+#!/usr/bin/perl
+
 # NOTE: (1) TP_HOME=.. works if tprocessor.cmd is started from the bin directory.
 #           Otherwise, set TP_HOME to point to the TProcessor installation directory, 
or use 
 #           the -home argument
@@ -9,13 +11,16 @@
 #       (6) DAV_AUTH specifies the authentication type which is enabled on the 
server. 
 #           Default os=operating system. 
 #       (4) DAV_GROUP is used for versions supporting groups and users.
-#      (4) DAV_DOMAIN is used for the domain specification of groups and users.
+#          (4) DAV_DOMAIN is used for the domain specification of groups and users.
 #       (6) DAV_USER and DAV_PASSWORD are used for authentication against the server.
 #       (7) TP_WORKDB internal DB name for the store configuration required for the 
webdav and I18N testcases ... :-(
 #       (8) TP_WORKHOST internal host name the internal DB for the store 
configuration required for the webdav and I18N testcases ... :-(
 
 use STRICT;
 
+print ("Apache Slide WebDAV Test Suite\n");
+print ("-------------------------------------------------------\n\n");
+
 $TP_WORKDB="xdavtest";
 $TP_WORKHOST="localhost";
 $DAV_HOST="localhost";
@@ -35,38 +40,95 @@
 
 if ($^O eq "MSWin32") {
   $PD="\\";
+  $PS=";";
 } else {
   $PD="/";
+  $PS=":";
 }
 
 if ($TP_HOME eq "") { 
   $TP_HOME="..";
 }
+
 # Process parms
-while (@ARGV && ($_ = $ARGV[0])){
+while (@ARGV && ($_ = $ARGV[0])) {
   $_ =~ tr/\//-/;      # allow slash as option identifier
-  if ($_ eq "-?" || $_ eq "-h" || $_ eq "-help") {usage(); exit();} 
-  elsif ($_ eq "-home")    {shift; $TP_HOME=$ARGV[0];} 
-  elsif ($_ eq "-davhost") {shift; $DAV_HOST=$ARGV[0];}
-  elsif ($_ eq "-davauth") {shift; $DAV_AUTH=$ARGV[0];}
-  elsif ($_ eq "-davgroup"){shift; $DAV_GROUP=$ARGV[0];}
-  elsif ($_ eq "-davdomain"){shift; $DAV_DOMAIN=$ARGV[0];}
-  elsif ($_ eq "-davuser") {shift; $DAV_USER=$ARGV[0];}
-  elsif ($_ eq "-davpassword") {shift; $DAV_PASSWORD=$ARGV[0];}
-  elsif ($_ eq "-davport") {shift; $DAV_PORT=$ARGV[0];}
-  elsif ($_ eq "-davname") {shift; $DAV_NAME=$ARGV[0];}
-  elsif ($_ eq "-store")   {shift; $TP_STORE=$ARGV[0];}
-  elsif ($_ eq "-users")   {shift; $TP_USERS=$ARGV[0];}
-  elsif ($_ eq "-iterations") {shift; $TP_ITERATIONS=$ARGV[0];}
-  elsif ($_ eq "-workdb")  {shift; $TP_WORKDB=$ARGV[0];}
-  elsif ($_ eq "-workhost"){shift; $TP_WORKHOST=$ARGV[0];}
-  elsif ($_ eq "-testcase"){shift; $TESTCASE_PATH=$ARGV[0];}
-  elsif ($_ eq "-pattern") {shift; $TESTCASE_PATTERN=$ARGV[0];}
-  elsif ($_ eq "-exclude") {shift; $TESTCASE_EXCLUDE=$ARGV[0];}
-  else {$PAR="$PAR $_";}
+  if ($_ eq "-?" || $_ eq "-h" || $_ eq "-help") {
+    usage(); exit();
+  } elsif ($_ eq "-home") {
+    shift; $TP_HOME=$ARGV[0];
+  } elsif ($_ eq "-davhost") {
+    shift; $DAV_HOST=$ARGV[0];
+  } elsif ($_ eq "-davauth") {
+    shift; $DAV_AUTH=$ARGV[0];
+  } elsif ($_ eq "-davgroup"){
+    shift; $DAV_GROUP=$ARGV[0];
+  } elsif ($_ eq "-davdomain"){
+    shift; $DAV_DOMAIN=$ARGV[0];
+  } elsif ($_ eq "-davuser") {
+    shift; $DAV_USER=$ARGV[0];
+  } elsif ($_ eq "-davpassword") {
+    shift; $DAV_PASSWORD=$ARGV[0];
+  } elsif ($_ eq "-davport") {
+    shift; $DAV_PORT=$ARGV[0];
+  } elsif ($_ eq "-davname") {
+    shift; $DAV_NAME=$ARGV[0];
+  } elsif ($_ eq "-store") {
+    shift; $TP_STORE=$ARGV[0];
+  } elsif ($_ eq "-users") {
+    shift; $TP_USERS=$ARGV[0];
+  } elsif ($_ eq "-iterations") {
+    shift; $TP_ITERATIONS=$ARGV[0];
+  } elsif ($_ eq "-workdb") {
+    shift; $TP_WORKDB=$ARGV[0];
+  } elsif ($_ eq "-workhost"){
+    shift; $TP_WORKHOST=$ARGV[0];
+  } elsif ($_ eq "-testcase") {
+    shift; $TESTCASE_PATH=$ARGV[0];
+  } elsif ($_ eq "-pattern") {
+    shift; $TESTCASE_PATTERN=$ARGV[0];
+  } elsif ($_ eq "-exclude") {
+    shift; $TESTCASE_EXCLUDE=$ARGV[0];
+  } else {
+    $PAR="$PAR $_";
+  }
   shift;
 }
 
+$CP="";
+$path="$TP_HOME"."$PD"."lib";
+print ("Adding libraries in \"$path\" to the classpath:\n");
+opendir (JD, "$path") || die "Cannot open $path";
+foreach (readdir(JD)) {
+    next if (substr($_, length($_) - 4, length($_)) ne ".jar");
+    print ("  adding $_\n");
+    if (!$CP) {
+        $CP="$path"."$PD"."$_";
+    } else {
+        $CP="$CP"."$PS"."$path"."$PD"."$_";
+    }
+}
+closedir JD;
+
+print ("\nTest parameters: \n");
+print ("  using home directory... $TP_HOME\n");
+print ("  using WebDAV host... $DAV_HOST\n");
+print ("  using WebDAV authentication... $DAV_AUTH\n");
+print ("  using group... $DAV_GROUP\n");
+print ("  using domain... $DAV_HOST\n");
+print ("  using user... $DAV_USER\n");
+print ("  using password... $DAV_PASSWORD\n");
+print ("  using port... $DAV_PORT\n");
+print ("  using name... $DAV_NAME\n");
+print ("  using store... $TP_STORE\n");
+print ("  using users... $TP_USERS\n");
+print ("  using iterations... $TP_ITERATIONS\n");
+print ("  using working database... $TP_WORKDB\n");
+print ("  using working host... $TP_WORKHOST\n");
+print ("  using testcase... $TESTCASE_PATH\n");
+print ("  using pattern... $TESTCASE_PATTER\n");
+print ("  using exclude... $TESTCASE_EXCLUDE\n\n");
+
 $TP_ITER_SMALL=int ($TP_ITERATIONS/2);
 
 if ("$DAV_AUTH" eq "none") {
@@ -103,10 +165,6 @@
   $ACTION_PATH="/$DAV_NAME/administration/security/actions";
 }
 
-$OPTS="-Dxdav.home=\"$TP_HOME\" -Dxdav.host=$DAV_HOST -Dxdav.port=$DAV_PORT 
-Dxdav.user=$DAV_USER -Dxdav.password=$DAV_PASSWORD 
-Dxdav.globalVariableDomainName=$DAV_DOMAIN -Dxdav.globalVariableGroupsColl=groups 
-Dxdav.globalVariableUsersColl=users -Dxdav.globalVariableRolesColl=roles 
-Dxdav.globalVariableGroup=$DAV_GROUP 
-Dxdav.globalVariableRootUserPath=$ROOT_USER_PATH 
-Dxdav.globalVariableUserPath=$USER_PATH -Dxdav.globalVariableServerName=$DAV_NAME 
-Dxdav.globalVariableCollection=$TP_STORE -Dxdav.globalVariableUsers=$TP_USERS 
-Dxdav.globalVariableIterationCount=$TP_ITERATIONS 
-Dxdav.globalVariableIterationCountSmall=$TP_ITER_SMALL 
-Dxdav.globalVariablePerformanceIterations=$TP_ITER_SMALL -Dxdav.urlencoding=UTF-8 
-Dxdav.workdb=$TP_WORKDB -Dxdav.workhost=$TP_WORKHOST 
-Dhttpclient.authentication.preemptive=true";
-
-$ENV{"CLASSPATH"}="";
-cpbuild("$TP_HOME"."$PD"."lib");
 
 if ("$TESTCASE_PATH") {
   $CLS="org.apache.slide.testsuite.testtools.tprocessor.TProcessors -name 
$TP_HOME$PD$TESTCASE_PATH";
@@ -122,11 +180,13 @@
   $PAR="org.apache.slide.testsuite.testtools.walker.TProcessorTestExecuter";
 }
 
+$OPTS="-Dxdav.home=\"$TP_HOME\" -Dxdav.host=$DAV_HOST -Dxdav.port=$DAV_PORT 
-Dxdav.user=$DAV_USER -Dxdav.password=$DAV_PASSWORD 
-Dxdav.globalVariableDomainName=$DAV_DOMAIN -Dxdav.globalVariableGroupsColl=groups 
-Dxdav.globalVariableUsersColl=users -Dxdav.globalVariableRolesColl=roles 
-Dxdav.globalVariableGroup=$DAV_GROUP 
-Dxdav.globalVariableRootUserPath=$ROOT_USER_PATH 
-Dxdav.globalVariableUserPath=$USER_PATH -Dxdav.globalVariableServerName=$DAV_NAME 
-Dxdav.globalVariableCollection=$TP_STORE -Dxdav.globalVariableUsers=$TP_USERS 
-Dxdav.globalVariableIterationCount=$TP_ITERATIONS 
-Dxdav.globalVariableIterationCountSmall=$TP_ITER_SMALL 
-Dxdav.globalVariablePerformanceIterations=$TP_ITER_SMALL -Dxdav.urlencoding=UTF-8 
-Dxdav.workdb=$TP_WORKDB -Dxdav.workhost=$TP_WORKHOST 
-Dhttpclient.authentication.preemptive=true";
+
 $JH=$ENV{"JAVA_HOME"};
 $CMD="$JH"."$PD"."bin"."$PD"."java";
-# print ("\"$CMD\" $OPTS $CLS $PAR\n");
-print ("$CMD $OPTS $CLS $PAR\n");
-system ("$CMD $OPTS $CLS $PAR");
+#print ("$CMD -cp $CP $OPTS $CLS $PAR\n");
+
+system ("$CMD -cp $CP $OPTS $CLS $PAR");
 
 
 sub usage {
@@ -166,21 +226,4 @@
   tprocessor -pattern *\\copy\\*.xml
 EOU
  ;
-}
-
-sub cpbuild {
-  $path=$_[0];
-  $CP="";
-  print "Appending $path and all jar files contained in $path to the 
classpath...\n\n";
-  $wrk=$ENV{"CLASSPATH"};
-  $ENV{"CLASSPATH"}="$wrk".";$path";
-  print ("Opening \"$path\"\n");
-  opendir (JD, "$path") || die "Cannot open $path";
-  foreach (readdir(JD)) {
-    next if (substr($_, length($_) - 4, length($_)) ne ".jar");
-    if (!$CP) {$CP="$path"."$PD"."$_";}
-    else {$CP="$CP".";$path$PD$_";}
-  }
-  $ENV{"CLASSPATH"}=$ENV{"CLASSPATH"}.";$CP";
-  closedir JD;
 }

Attachment: smime.p7s
Description: S/MIME cryptographic signature



Reply via email to