#!perl
-use Test::More tests => 9;
+use Test::More tests => 10;
use strict;
use warnings;
use HTTP::Request;
use HTTP::Request::AsCGI;
-my $r = HTTP::Request->new( GET => 'http://www.host.com/my/path/?a=1&b=2' );
+my $r = HTTP::Request->new( GET => 'http://www.host.com/my/path/?a=1&b=2', [ 'X-Test' => 'Test' ] );
my $c = HTTP::Request::AsCGI->new($r);
$c->stdout(undef);
is( $ENV{GATEWAY_INTERFACE}, 'CGI/1.1', 'GATEWAY_INTERFACE' );
is( $ENV{HTTP_HOST}, 'www.host.com:80', 'HTTP_HOST' );
+is( $ENV{HTTP_X_TEST}, 'Test', 'HTTP_X_TEST' );
is( $ENV{PATH_INFO}, '/my/path/', 'PATH_INFO' );
is( $ENV{QUERY_STRING}, 'a=1&b=2', 'QUERY_STRING' );
is( $ENV{SCRIPT_NAME}, '/', 'SCRIPT_NAME' );