@kumwe/studio-testkit 0.1.0-alpha.6 → 0.1.0-alpha.7
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.
- package/README.md +28 -2
- package/corpus-manifest.json +760 -0
- package/dist/host-testbed.d.ts.map +1 -1
- package/dist/host-testbed.js +131 -0
- package/dist/host-testbed.js.map +1 -1
- package/dist/http-host-adapter.d.ts.map +1 -1
- package/dist/http-host-adapter.js +15 -0
- package/dist/http-host-adapter.js.map +1 -1
- package/fixtures/field-adapter.example.json +27 -0
- package/fixtures/host-capabilities.example.json +9 -3
- package/fixtures/host-operations.example.json +270 -0
- package/fixtures/inspector.example.json +17 -0
- package/fixtures/media-upload-grant.example.json +14 -0
- package/fixtures/studio-config.example.json +1 -1
- package/invalid/inspector.empty-block-types.json +20 -0
- package/invalid/media-upload-grant.insecure-url.json +14 -0
- package/invalid/preview-message.activated-unknown-interaction.json +16 -0
- package/invalid/preview-message.viewport-role-and-size.json +16 -0
- package/package.json +6 -4
- package/vectors/canonical/array-order.json +13 -0
- package/vectors/canonical/control-characters.json +13 -0
- package/vectors/canonical/depth-exceeded.json +21 -0
- package/vectors/canonical/empty-containers.json +14 -0
- package/vectors/canonical/forbidden-member.json +14 -0
- package/vectors/canonical/member-order.json +16 -0
- package/vectors/canonical/negative-zero.json +13 -0
- package/vectors/canonical/nested-order.json +19 -0
- package/vectors/canonical/non-ascii.json +13 -0
- package/vectors/canonical/numbers.json +16 -0
- package/vectors/canonical/string-escapes.json +13 -0
- package/vectors/canonical/surrogate-pair.json +13 -0
- package/vectors/host/artifact.dependencies.result.json +35 -0
- package/vectors/host/artifact.load.stored.json +36 -0
- package/vectors/host/artifact.load.unknown.error.json +37 -0
- package/vectors/host/artifact.publish.accepted.json +37 -0
- package/vectors/host/artifact.publish.forbidden.error.json +37 -0
- package/vectors/host/artifact.publish.stale.error.json +38 -0
- package/vectors/host/artifact.save.accepted.json +38 -0
- package/vectors/host/artifact.save.forbidden.error.json +38 -0
- package/vectors/host/artifact.save.stale.error.json +39 -0
- package/vectors/host/artifact.unpublish.stale.error.json +38 -0
- package/vectors/host/envelope.malformed-context.error.json +36 -0
- package/vectors/host/envelope.protocol-version.error.json +36 -0
- package/vectors/host/envelope.stale-generation.error.json +36 -0
- package/vectors/host/localization.messages.unknown-locale.error.json +36 -0
- package/vectors/host/media.abort-upload.unknown.error.json +35 -0
- package/vectors/host/media.authorize-upload.granted.json +37 -0
- package/vectors/host/media.authorize-upload.path-filename.error.json +39 -0
- package/vectors/host/media.authorize-upload.too-large.error.json +38 -0
- package/vectors/host/media.complete-upload.unknown.error.json +36 -0
- package/vectors/host/media.get.unknown.json +34 -0
- package/vectors/host/media.import-external.private-host.error.json +36 -0
- package/vectors/host/media.list.cursor.error.json +36 -0
- package/vectors/host/media.list.limit.error.json +35 -0
- package/vectors/host/media.upload-status.unknown.error.json +35 -0
- package/vectors/host/permission.explain.withheld.json +34 -0
- package/vectors/host/permission.refresh.snapshot.json +31 -0
- package/vectors/host/recovery.load.absent.json +31 -0
- package/vectors/host/telemetry.emit.accepted.json +37 -0
- package/vectors/host/telemetry.emit.non-primitive.error.json +40 -0
package/README.md
CHANGED
|
@@ -33,7 +33,33 @@ the `sessionGeneration` getter, and the recorded `telemetryEvents` support asser
|
|
|
33
33
|
`createHostRequestContextFixture` builds conforming request envelopes. The testbed uses no clocks,
|
|
34
34
|
randomness, or timers, so runs are fully reproducible.
|
|
35
35
|
|
|
36
|
+
## Host conformance corpus
|
|
37
|
+
|
|
38
|
+
`@kumwe/studio-testkit/vectors/host/<filename>` publishes the executable assertion set for
|
|
39
|
+
`studio.profile/host-baseline`. Each vector is language-neutral JSON conforming to
|
|
40
|
+
`host-vector.schema.json`: it fixes the host state to seed (`given`), the request envelope and
|
|
41
|
+
argument to send (`context`, `argument`), and the required outcome (`expect`) — an accepted result
|
|
42
|
+
with its revision behaviour, or one category of the closed error taxonomy with its retry
|
|
43
|
+
classification and non-disclosure obligations. Every precondition is a condition a real host
|
|
44
|
+
reproduces, never a test double, so an adapter written in any language replays the corpus in its own
|
|
45
|
+
test suite without executing Studio code. The reference host's own claim against the profile is
|
|
46
|
+
`test/host-vectors.test.ts`. The profile records the obligations it does not yet assert; consult
|
|
47
|
+
`docs/contracts/conformance-profiles.md` before treating a green replay as complete coverage.
|
|
48
|
+
|
|
49
|
+
`@kumwe/studio-testkit/vectors/canonical/<filename>` publishes the canonical serialization corpus:
|
|
50
|
+
each vector carries a bounded value and either the exact canonical string with the SRI-style digest of
|
|
51
|
+
its UTF-8 bytes, or the stable reason the canonical form refuses it. Its expectations were produced by
|
|
52
|
+
an independent canonicalizer rather than recorded from the reference implementation, so replaying it
|
|
53
|
+
is a cross-implementation check.
|
|
54
|
+
|
|
55
|
+
`@kumwe/studio-testkit/corpus-manifest.json` carries the sha256 digest of every file in the published
|
|
56
|
+
corpus, grouped by the directory it ships in. A host that vendors the corpus verifies its copy against
|
|
57
|
+
this manifest, so a stale or altered fixture is detected before it silently changes what a conformance
|
|
58
|
+
claim means. The schema manifest in `@kumwe/studio-protocol` covers the schemas; this covers everything
|
|
59
|
+
replayed against them.
|
|
60
|
+
|
|
36
61
|
Gate A requires valid and invalid fixture corpora plus runner-neutral assertions for block, theme,
|
|
37
62
|
plugin, host-port, command, preview, media, compatibility, migration, lifecycle, security,
|
|
38
|
-
accessibility, localization, and TypeScript/Dart equivalence.
|
|
39
|
-
foundation alpha must not be cited as
|
|
63
|
+
accessibility, localization, and TypeScript/Dart equivalence. The host-port corpus above is the first
|
|
64
|
+
of those to land; the remainder are target deliverables and this foundation alpha must not be cited as
|
|
65
|
+
their evidence.
|