Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions enterprise/e2e/html/hurl/draft3.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-03/schema#",
"id": "{{base}}/test/draft3/string",
Expand Down Expand Up @@ -65,6 +66,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-03/schema#",
"id": "{{base}}/test/draft3/with-ref",
Expand All @@ -87,6 +89,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-03/schema#",
"id": "{{base}}/test/draft3/with-ref",
Expand Down
1 change: 1 addition & 0 deletions enterprise/e2e/html/hurl/list.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/"
jsonpath "$.url" == "{{base}}"
Expand Down
1 change: 1 addition & 0 deletions enterprise/e2e/html/hurl/schemas-health.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.score" == 67
jsonpath "$.errors" count == 1
Expand Down
2 changes: 2 additions & 0 deletions enterprise/e2e/html/hurl/self.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.entries[*].name" includes "self"

Expand Down Expand Up @@ -50,6 +51,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.entries" count >= 1

Expand Down
2 changes: 2 additions & 0 deletions enterprise/e2e/path/hurl/fetch-draft3.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-03/schema#",
"id": "{{base}}/v1/catalog/draft3/string",
Expand Down Expand Up @@ -62,6 +63,7 @@ header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
bytes count == 0
header "ETag" == {{draft3_string_etag}}
header "Vary" == "Accept-Encoding"
header "Content-Length" == {{draft3_string_content_length}}

GET {{base}}/v1/catalog/draft3/nonexistent.json
Expand Down
40 changes: 30 additions & 10 deletions src/router/artifact.cc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <exception> // std::exception
#include <filesystem> // std::filesystem
#include <optional> // std::optional
#include <sstream> // std::ostringstream
#include <string> // std::string
#include <string_view> // std::string_view
#include <utility> // std::move
Expand Down Expand Up @@ -164,15 +163,26 @@ auto RouterAction::artifact_serve(
return;
}

// Our checksum is computed over the identity (uncompressed) payload at
// index time. When the wire response is gzip-encoded the wire bytes are
// not what the checksum covers, so per RFC 9110 §8.8.1 the validator must
// be marked weak:
//
// "if the origin server sends the same validator for a representation
// with a gzip content coding applied as it does for a representation
// with no content coding, then that validator is weak."
//
// https://datatracker.ietf.org/doc/html/rfc9110#section-8.8.1
//
// When the wire response is identity, the wire bytes exactly match what
// the checksum covers, so the validator can be strong.
const auto &checksum{info->checksum_hex};
std::ostringstream etag_value_strong;
std::ostringstream etag_value_weak;
etag_value_strong << '"' << checksum << '"';
etag_value_weak << 'W' << '/' << '"' << checksum << '"';
const std::string etag_strong{std::string{"\""} + checksum + "\""};
const std::string etag_weak{std::string{"W/\""} + checksum + "\""};
for (const auto &match : request.header_list("if-none-match")) {
// Cache hit
if (match.first == "*" || match.first == etag_value_weak.str() ||
match.first == etag_value_strong.str()) {
if (match.first == "*" || match.first == etag_weak ||
match.first == etag_strong) {
response.write_status(sourcemeta::one::STATUS_NOT_MODIFIED);
if (enable_cors) {
response.write_header("Access-Control-Allow-Origin", "*");
Expand Down Expand Up @@ -208,9 +218,19 @@ auto RouterAction::artifact_serve(
response.write_header("Last-Modified",
sourcemeta::core::to_gmt(info->last_modified));

std::ostringstream etag;
etag << '"' << checksum << '"';
response.write_header("ETag", std::move(etag).str());
response.write_header("ETag", request.response_encoding() ==
Comment thread
jviotti marked this conversation as resolved.
Comment thread
jviotti marked this conversation as resolved.
sourcemeta::one::Encoding::GZIP
? etag_weak
: etag_strong);

// RFC 9110 §12.5.5: emit Vary on cacheable responses so shared caches key
// the entry by the request headers that select the representation. The
// wire encoding and the ETag form (strong vs weak per RFC 9110 §8.8.1)
// both vary with `Accept-Encoding`; without this header a shared cache
// can serve the gzip variant to a client that didn't request gzip, or
// the strong-form ETag against a weak-form cached entry.
// https://datatracker.ietf.org/doc/html/rfc9110#section-12.5.5
response.write_header("Vary", "Accept-Encoding");

// See
// https://json-schema.org/draft/2020-12/json-schema-core.html#section-9.5.1.1
Expand Down
1 change: 1 addition & 0 deletions test/e2e/empty/hurl/test.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/"
jsonpath "$.url" == "{{base}}"
Expand Down
4 changes: 4 additions & 0 deletions test/e2e/headless/hurl/bundle.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/bundling-single.json?bundle=1
HTTP 200
Expand Down Expand Up @@ -99,6 +100,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/no-id.json?bundle=1
HTTP 200
Expand Down Expand Up @@ -150,6 +152,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "{{base}}/test/schemas/bundling-single",
Expand Down Expand Up @@ -180,6 +183,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "{{base}}/test/schemas/bundling-single",
Expand Down
1 change: 1 addition & 0 deletions test/e2e/headless/hurl/etag.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" == {{test_schemas_string_json_etag}}
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/string.json
If-None-Match: {{test_schemas_string_json_etag}}
Expand Down
10 changes: 10 additions & 0 deletions test/e2e/headless/hurl/fetch.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/string.json
HTTP 200
Expand Down Expand Up @@ -48,6 +49,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/string
HTTP 200
Expand Down Expand Up @@ -206,6 +208,7 @@ header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
bytes count == 0
header "ETag" == {{test_schemas_string_json_etag}}
header "Vary" == "Accept-Encoding"
header "Content-Length" == {{test_schemas_string_json_content_length}}

POST {{base}}/test/schemas/string.json
Expand Down Expand Up @@ -258,6 +261,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "{{base}}/test/no-base/no-id",
Expand All @@ -275,6 +279,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "{{base}}/test/no-base/test-1",
Expand Down Expand Up @@ -302,6 +307,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"

GET {{base}}/test/schemas/string.JSON
HTTP 200
Expand All @@ -314,6 +320,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
body == "{{case_baseline_body}}"

GET {{base}}/test/schemas/string.Json
Expand All @@ -327,6 +334,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
body == "{{case_baseline_body}}"

GET {{base}}/test/schemas/STRING.json
Expand All @@ -340,6 +348,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
body == "{{case_baseline_body}}"

GET {{base}}/TEST/SCHEMAS/STRING.JSON
Expand All @@ -353,4 +362,5 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
body == "{{case_baseline_body}}"
5 changes: 5 additions & 0 deletions test/e2e/headless/hurl/list.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/"
jsonpath "$.url" == "{{base}}"
Expand Down Expand Up @@ -59,6 +60,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/test"
jsonpath "$.url" == "{{base}}/test"
Expand Down Expand Up @@ -130,6 +132,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/"
jsonpath "$.url" == "{{base}}"
Expand Down Expand Up @@ -180,6 +183,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/test"
jsonpath "$.url" == "{{base}}/test"
Expand Down Expand Up @@ -228,6 +232,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$.path" == "/test"
jsonpath "$.url" == "{{base}}/test"
Expand Down
5 changes: 5 additions & 0 deletions test/e2e/headless/hurl/schemas-dependencies.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 1
jsonpath "$[0].from" == "{{base}}/test/schemas/bundling-single"
Expand Down Expand Up @@ -45,6 +46,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 0

Expand Down Expand Up @@ -75,6 +77,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 0

Expand Down Expand Up @@ -105,6 +108,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 0

Expand Down Expand Up @@ -132,6 +136,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
bytes count == 0

Expand Down
5 changes: 5 additions & 0 deletions test/e2e/headless/hurl/schemas-dependents.all.hurl
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 3
jsonpath "$[0].from" == "{{base}}/test/schemas/bundling-double"
Expand Down Expand Up @@ -48,6 +49,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 4
jsonpath "$[0].from" == "{{base}}/test/schemas/bundling-double"
Expand Down Expand Up @@ -86,6 +88,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 0

Expand Down Expand Up @@ -116,6 +119,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
jsonpath "$" count == 0

Expand Down Expand Up @@ -143,6 +147,7 @@ header "Content-Security-Policy" not exists
header "X-Frame-Options" not exists
header "Date" matches /^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (0[1-9]|[12][0-9]|3[01]) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) [0-9]{4} ([01][0-9]|2[0-3]):[0-5][0-9]:[0-5][0-9] GMT$/
header "ETag" exists
header "Vary" == "Accept-Encoding"
header "Last-Modified" exists
bytes count == 0

Expand Down
Loading
Loading