-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Juan Cruz Viotti <[email protected]>
- Loading branch information
Showing
6 changed files
with
143 additions
and
2 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
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
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
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
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
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,122 @@ | ||
# HEAD | ||
HEAD {{base}}/style.min.css | ||
HTTP 200 | ||
Content-Type: text/css | ||
[Asserts] | ||
bytes count == 0 | ||
|
||
# Without GZIP | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
Content-Type: text/css | ||
[Asserts] | ||
bytes count > 0 | ||
|
||
# With GZIP | ||
GET {{base}}/style.min.css | ||
Accept-Encoding: gzip | ||
HTTP 200 | ||
Content-Type: text/css | ||
Content-Encoding: gzip | ||
[Asserts] | ||
bytes count > 0 | ||
|
||
# Idempotent ETag | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "ETag" exists | ||
[Captures] | ||
css_etag: header "ETag" | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
bytes count > 0 | ||
header "ETag" == {{css_etag}} | ||
|
||
# If-None-Match with match | ||
GET {{base}}/style.min.css | ||
If-None-Match: {{css_etag}} | ||
HTTP 304 | ||
[Asserts] | ||
header "Content-Type" not exists | ||
bytes count == 0 | ||
|
||
# If-None-Match with weak match | ||
GET {{base}}/style.min.css | ||
If-None-Match: W/{{css_etag}} | ||
HTTP 304 | ||
[Asserts] | ||
header "Content-Type" not exists | ||
bytes count == 0 | ||
|
||
# If-None-Match without match | ||
GET {{base}}/style.min.css | ||
If-None-Match: "12345" | ||
HTTP 200 | ||
Content-Type: text/css | ||
[Asserts] | ||
bytes count > 0 | ||
|
||
# Last-Modified | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "Last-Modified" matches /^(Sun|Mon|Tue|Wed|Thu|Fri|Sat), [0-3][0-9] (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} [0-2][0-9]:[0-5][0-9]:[0-5][0-9] GMT$/ | ||
|
||
# Idempotent Last-Modified | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "Last-Modified" exists | ||
[Captures] | ||
css_last_modified: header "Last-Modified" | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "Last-Modified" == {{css_last_modified}} | ||
|
||
# Invalid If-Modified-Since | ||
GET {{base}}/style.min.css | ||
If-Modified-Since: FOO | ||
Content-Type: text/css | ||
HTTP 200 | ||
[Asserts] | ||
bytes count > 0 | ||
|
||
# If-Modified-Since exact | ||
GET {{base}}/style.min.css | ||
If-Modified-Since: {{css_last_modified}} | ||
HTTP 304 | ||
[Asserts] | ||
header "Content-Type" not exists | ||
bytes count == 0 | ||
|
||
# If-Modified-Since false | ||
GET {{base}}/style.min.css | ||
If-Modified-Since: Thu, 01 Jan 2100 00:00:00 GMT | ||
HTTP 304 | ||
[Asserts] | ||
header "Content-Type" not exists | ||
bytes count == 0 | ||
|
||
# If-Modified-Since true | ||
GET {{base}}/style.min.css | ||
If-Modified-Since: Thu, 01 Jan 1970 00:00:00 GMT | ||
HTTP 200 | ||
Content-Type: text/css | ||
[Asserts] | ||
bytes count > 0 | ||
|
||
# Proper HEAD | ||
GET {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "Content-Length" exists | ||
[Captures] | ||
css_content_length: header "Content-Length" | ||
HEAD {{base}}/style.min.css | ||
HTTP 200 | ||
[Asserts] | ||
header "Content-Length" exists | ||
header "Content-Length" == {{css_content_length}} |