#!/usr/local/bin/perl -w # Due to a bug in older versions of MakeMaker & Test::Harness, we must # ensure the blib's are in @INC, else we might use the core CGI.pm use lib qw(. ./blib/lib ./blib/arch); use Test::More tests => 19; BEGIN { use_ok('CGI'); }; use CGI (':standard','-no_debug','-tabindex'); my $CRLF = "\015\012"; if ($^O eq 'VMS') { $CRLF = "\n"; # via web server carriage is inserted automatically } if (ord("\t") != 9) { # EBCDIC? $CRLF = "\r\n"; } # Set up a CGI environment $ENV{REQUEST_METHOD} = 'GET'; $ENV{QUERY_STRING} = 'game=chess&game=checkers&weather=dull'; $ENV{PATH_INFO} = '/somewhere/else'; $ENV{PATH_TRANSLATED} = '/usr/local/somewhere/else'; $ENV{SCRIPT_NAME} ='/cgi-bin/foo.cgi'; $ENV{SERVER_PROTOCOL} = 'HTTP/1.0'; $ENV{SERVER_PORT} = 8080; $ENV{SERVER_NAME} = 'the.good.ship.lollypop.com'; is(start_form(-action=>'foobar',-method=>'get'), qq(