Skip to content

Instantly share code, notes, and snippets.

@bduggan
Created September 13, 2011 14:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bduggan/1213892 to your computer and use it in GitHub Desktop.
Save bduggan/1213892 to your computer and use it in GitHub Desktop.
MOJO_USERAGENT_DEBUG=1 perl t/mojolicious/redirect_headers.t
1..2
NEW BLOCKING REQUEST
TEST SERVER STARTED (http://*:17728)
NEW CONNECTION (http:localhost:17728)
> GET /first HTTP/1.1
User-Agent: Mojolicious (Perl)
Connection: Close
Content-Length: 0
Host: localhost:17728
< HTTP/1.1 302 Found
Connection: close
X-Powered-By: Mojolicious (Perl)
Location: http://localhost:17728/second
Date: Tue, 13 Sep 2011 14:09:06 GMT
Content-Length: 0
Server: Mojolicious (Perl)
NEW CONNECTION (http:localhost:17728)
> GET /second HTTP/1.1
User-Agent: Mojolicious (Perl)
Connection: keep-alive
Content-Length: 0
Host: localhost:17728
< HTTP/1.1 200 OK
Connection: keep-alive
Content-Type: text/html;charset=UTF-8
X-Powered-By: Mojolicious (Perl)
Date: Tue, 13 Sep 2011 14:09:06 GMT
Content-Length: 23
Server: Mojolicious (Perl)
Connection : keep-alive
ok 1 - get /first
not ok 2 - exact match for content
# Failed test 'exact match for content'
# at t/mojolicious/redirect_headers.t line 19.
# got: 'Connection : keep-alive'
# expected: 'Connection : Close'
DROPPING ALL CONNECTIONS
# Looks like you failed 1 test of 2.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment