Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
well...added echo-client-request-headers.t for real this time
- Loading branch information
Showing
1 changed file
with
44 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# vi:filetype=perl | ||
|
||
use lib 'lib'; | ||
use Test::Nginx::Echo; | ||
|
||
plan tests => 1 * blocks(); | ||
|
||
run_tests(); | ||
|
||
__DATA__ | ||
=== TEST 1: standalone directive | ||
--- config | ||
location /echo { | ||
echo_client_request_headers; | ||
} | ||
--- request | ||
GET /echo | ||
--- response_body eval | ||
"GET /echo HTTP/1.1\r | ||
Host: localhost:\$ServerPort\r | ||
User-Agent: Test::Nginx::Echo\r | ||
\r | ||
" | ||
=== TEST 2: multiple instances | ||
--- config | ||
location /echo { | ||
echo_client_request_headers; | ||
echo_client_request_headers; | ||
} | ||
--- request | ||
GET /echo | ||
--- response_body eval | ||
"GET /echo HTTP/1.1\r | ||
Host: localhost:\$ServerPort\r | ||
User-Agent: Test::Nginx::Echo\r | ||
\r | ||
GET /echo HTTP/1.1\r | ||
Host: localhost:\$ServerPort\r | ||
User-Agent: Test::Nginx::Echo\r | ||
\r | ||
" |