@aventara/testing 0.1.0-pilot.0 → 0.1.0-pilot.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -834,17 +834,24 @@ const identityHeaders = (requestId, overrides = {}, omit) => Object.fromEntries(
|
|
|
834
834
|
const STALE_CLIENT = "Generated client contract does not match the server. Regenerate the client.";
|
|
835
835
|
/**
|
|
836
836
|
* Family 5 — identity (§12.4; S7 follow-ups): a request missing either
|
|
837
|
-
* identity header is malformed (`A2000
|
|
837
|
+
* identity header is malformed (`A2000`, its message naming the missing
|
|
838
|
+
* header(s) — pilot.1 — and never a value), another protocol version is
|
|
838
839
|
* `A2006`, a stale or malformed hash is `A2005` with Appendix B.3's text (Q3),
|
|
839
840
|
* all on a route that exists; header names are matched without regard to case.
|
|
840
841
|
*/
|
|
841
842
|
const IDENTITY = [
|
|
842
843
|
refused("identity: no Aventara-Protocol-Version → 400 A2000", corpusRequest("find/many", {}, "corpus-id-no-version", {
|
|
843
844
|
headers: identityHeaders("corpus-id-no-version", {}, "Aventara-Protocol-Version"),
|
|
844
|
-
}), 400, "A2000",
|
|
845
|
+
}), 400, "A2000", "The Aventara-Protocol-Version header is missing."),
|
|
845
846
|
refused("identity: no Aventara-Contract-Hash → 400 A2000", corpusRequest("find/many", {}, "corpus-id-no-hash", {
|
|
846
847
|
headers: identityHeaders("corpus-id-no-hash", {}, "Aventara-Contract-Hash"),
|
|
847
|
-
}), 400, "A2000",
|
|
848
|
+
}), 400, "A2000", "The Aventara-Contract-Hash header is missing."),
|
|
849
|
+
refused("identity: neither identity header → 400 A2000 naming both", corpusRequest("find/many", {}, "corpus-id-none", {
|
|
850
|
+
headers: {
|
|
851
|
+
"Content-Type": "application/json",
|
|
852
|
+
"Aventara-Request-Id": "corpus-id-none",
|
|
853
|
+
},
|
|
854
|
+
}), 400, "A2000", "The Aventara-Protocol-Version and Aventara-Contract-Hash headers are missing."),
|
|
848
855
|
refused("identity: another protocol version → 400 A2006", corpusRequest("find/many", {}, "corpus-id-version", {
|
|
849
856
|
headers: identityHeaders("corpus-id-version", {
|
|
850
857
|
"Aventara-Protocol-Version": "2",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aventara/testing",
|
|
3
|
-
"version": "0.1.0-pilot.
|
|
3
|
+
"version": "0.1.0-pilot.1",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
5
|
"description": "Conformance and extension testing utilities for Aventara.",
|
|
6
6
|
"type": "module",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"LICENSE-ADDITIONAL-PERMISSION.md"
|
|
21
21
|
],
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@aventara/core": "0.1.0-pilot.
|
|
23
|
+
"@aventara/core": "0.1.0-pilot.1"
|
|
24
24
|
},
|
|
25
25
|
"publishConfig": {
|
|
26
26
|
"access": "public"
|