Loading tests/getpart.pm +8 −1 Original line number Diff line number Diff line Loading @@ -92,8 +92,15 @@ sub getpart { sub loadtest { my ($file)=@_; my $dir; $dir = $ENV{'srcdir'}; if(!$dir) { $dir="."; } undef @xml; open(XML, "<$file") || open(XML, "<$dir/$file") || return 1; # failure! binmode XML; # for crapage systems, use binary while(<XML>) { Loading tests/httpserver.pl +6 −1 Original line number Diff line number Diff line Loading @@ -4,14 +4,19 @@ use strict; my $verbose=0; # set to 1 for debugging my $dir="."; my $port = 8999; # just a default do { if($ARGV[0] eq "-v") { $verbose=1; } elsif($ARGV[0] eq "-d") { $dir=$ARGV[1]; shift @ARGV; } elsif($ARGV[0] =~ /^(\d+)$/) { $port = $1; } } while(shift @ARGV); exec("server/sws $port"); exec("server/sws $port $dir"); tests/runtests.pl +8 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ my $FTPSPORT=8821; # this is the FTPS server port my $CURL="../src/curl"; # what curl executable to run on the tests my $DBGCURL=$CURL; #"../src/.libs/curl"; # alternative for debugging my $LOGDIR="log"; my $TESTDIR="data"; my $TESTDIR="$srcdir/data"; my $LIBDIR="./libtest"; my $SERVERIN="$LOGDIR/server.input"; # what curl sent the server my $CURLLOG="$LOGDIR/curl.log"; # all command lines run Loading Loading @@ -354,6 +354,10 @@ sub runhttpserver { } my $flag=$debugprotocol?"-v ":""; my $dir=$ENV{'srcdir'}; if($dir) { $flag .= "-d \"$dir\" "; } $cmd="$perl $srcdir/httpserver.pl $flag $HOSTPORT &"; system($cmd); if($verbose) { Loading Loading @@ -691,6 +695,9 @@ sub checkcurl { } } } if(!$curl) { die "couldn't run curl!" } my $hostname=`hostname`; my $hosttype=`uname -a`; Loading tests/server/sws.c +11 −3 Original line number Diff line number Diff line Loading @@ -70,7 +70,10 @@ spitout(FILE *stream, #define REQUEST_DUMP "log/server.input" #define RESPONSE_DUMP "log/server.response" #define TEST_DATA_PATH "data/test%d" #define TEST_DATA_PATH "%s/data/test%d" /* global variable, where to find the 'data' dir */ char *path="."; enum { DOCNUMBER_QUIT = -6, Loading Loading @@ -442,7 +445,7 @@ static int send_doc(int sock, if(0 != part_no) sprintf(partbuf, "data%d", part_no); sprintf(filename, TEST_DATA_PATH, doc); sprintf(filename, TEST_DATA_PATH, path, doc); stream=fopen(filename, "rb"); if(!stream) { Loading Loading @@ -537,9 +540,14 @@ int main(int argc, char *argv[]) int part_no; FILE *pidfile; if(argc>1) if(argc>1) { port = atoi(argv[1]); if(argc>2) { path = argv[2]; } } logfp = fopen(logfile, "a"); if (!logfp) { perror(logfile); Loading Loading
tests/getpart.pm +8 −1 Original line number Diff line number Diff line Loading @@ -92,8 +92,15 @@ sub getpart { sub loadtest { my ($file)=@_; my $dir; $dir = $ENV{'srcdir'}; if(!$dir) { $dir="."; } undef @xml; open(XML, "<$file") || open(XML, "<$dir/$file") || return 1; # failure! binmode XML; # for crapage systems, use binary while(<XML>) { Loading
tests/httpserver.pl +6 −1 Original line number Diff line number Diff line Loading @@ -4,14 +4,19 @@ use strict; my $verbose=0; # set to 1 for debugging my $dir="."; my $port = 8999; # just a default do { if($ARGV[0] eq "-v") { $verbose=1; } elsif($ARGV[0] eq "-d") { $dir=$ARGV[1]; shift @ARGV; } elsif($ARGV[0] =~ /^(\d+)$/) { $port = $1; } } while(shift @ARGV); exec("server/sws $port"); exec("server/sws $port $dir");
tests/runtests.pl +8 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ my $FTPSPORT=8821; # this is the FTPS server port my $CURL="../src/curl"; # what curl executable to run on the tests my $DBGCURL=$CURL; #"../src/.libs/curl"; # alternative for debugging my $LOGDIR="log"; my $TESTDIR="data"; my $TESTDIR="$srcdir/data"; my $LIBDIR="./libtest"; my $SERVERIN="$LOGDIR/server.input"; # what curl sent the server my $CURLLOG="$LOGDIR/curl.log"; # all command lines run Loading Loading @@ -354,6 +354,10 @@ sub runhttpserver { } my $flag=$debugprotocol?"-v ":""; my $dir=$ENV{'srcdir'}; if($dir) { $flag .= "-d \"$dir\" "; } $cmd="$perl $srcdir/httpserver.pl $flag $HOSTPORT &"; system($cmd); if($verbose) { Loading Loading @@ -691,6 +695,9 @@ sub checkcurl { } } } if(!$curl) { die "couldn't run curl!" } my $hostname=`hostname`; my $hosttype=`uname -a`; Loading
tests/server/sws.c +11 −3 Original line number Diff line number Diff line Loading @@ -70,7 +70,10 @@ spitout(FILE *stream, #define REQUEST_DUMP "log/server.input" #define RESPONSE_DUMP "log/server.response" #define TEST_DATA_PATH "data/test%d" #define TEST_DATA_PATH "%s/data/test%d" /* global variable, where to find the 'data' dir */ char *path="."; enum { DOCNUMBER_QUIT = -6, Loading Loading @@ -442,7 +445,7 @@ static int send_doc(int sock, if(0 != part_no) sprintf(partbuf, "data%d", part_no); sprintf(filename, TEST_DATA_PATH, doc); sprintf(filename, TEST_DATA_PATH, path, doc); stream=fopen(filename, "rb"); if(!stream) { Loading Loading @@ -537,9 +540,14 @@ int main(int argc, char *argv[]) int part_no; FILE *pidfile; if(argc>1) if(argc>1) { port = atoi(argv[1]); if(argc>2) { path = argv[2]; } } logfp = fopen(logfile, "a"); if (!logfp) { perror(logfile); Loading