provide a source path to the servers to make them find the tests when run
[platform/upstream/curl.git] / tests / httpserver.pl
1 #!/usr/bin/env perl
2
3 use strict;
4
5 my $verbose=0; # set to 1 for debugging
6
7 my $dir=".";
8 my $port = 8999; # just a default
9 do {
10     if($ARGV[0] eq "-v") {
11         $verbose=1;
12     }
13     elsif($ARGV[0] eq "-d") {
14         $dir=$ARGV[1];
15         shift @ARGV;
16     }
17     elsif($ARGV[0] =~ /^(\d+)$/) {
18         $port = $1;
19     }
20 } while(shift @ARGV);
21
22 exec("server/sws $port $dir");