@fuzdev/fuz_app 0.168.1 → 0.170.0
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/dist/actions/CLAUDE.md +17 -19
- package/dist/actions/action_codegen.d.ts +32 -23
- package/dist/actions/action_codegen.d.ts.map +1 -1
- package/dist/actions/action_codegen.js +101 -80
- package/dist/actions/action_event.d.ts +0 -8
- package/dist/actions/action_event.d.ts.map +1 -1
- package/dist/actions/action_event.js +7 -6
- package/dist/actions/action_event_data.d.ts +18 -18
- package/dist/actions/action_rpc.d.ts +1 -1
- package/dist/actions/action_rpc.js +1 -1
- package/dist/actions/action_spec.d.ts +8 -10
- package/dist/actions/action_spec.d.ts.map +1 -1
- package/dist/actions/action_spec.js +1 -1
- package/dist/actions/action_types.d.ts +4 -4
- package/dist/actions/action_types.d.ts.map +1 -1
- package/dist/actions/action_types.js +2 -2
- package/dist/actions/broadcast_api.d.ts +2 -2
- package/dist/actions/broadcast_api.js +4 -4
- package/dist/actions/compile_action_registry.d.ts +6 -7
- package/dist/actions/compile_action_registry.d.ts.map +1 -1
- package/dist/actions/compile_action_registry.js +8 -9
- package/dist/actions/perform_action.d.ts +6 -6
- package/dist/actions/perform_action.d.ts.map +1 -1
- package/dist/actions/perform_action.js +11 -10
- package/dist/actions/socket.svelte.d.ts +1 -1
- package/dist/actions/socket.svelte.js +2 -2
- package/dist/auth/CLAUDE.md +11 -11
- package/dist/auth/account_action_specs.d.ts +11 -11
- package/dist/auth/account_action_specs.js +1 -1
- package/dist/auth/account_route_schema.d.ts +18 -18
- package/dist/auth/account_route_schema.js +1 -1
- package/dist/auth/account_routes.js +1 -1
- package/dist/auth/account_schema.d.ts +38 -40
- package/dist/auth/account_schema.d.ts.map +1 -1
- package/dist/auth/account_schema.js +7 -8
- package/dist/auth/actor_lookup_action_specs.d.ts +7 -7
- package/dist/auth/actor_lookup_action_specs.js +1 -1
- package/dist/auth/actor_search_action_specs.d.ts +6 -6
- package/dist/auth/actor_search_action_specs.js +1 -1
- package/dist/auth/admin_action_specs.d.ts +166 -166
- package/dist/auth/admin_action_specs.js +1 -1
- package/dist/auth/app_settings_schema.d.ts +3 -3
- package/dist/auth/app_settings_schema.d.ts.map +1 -1
- package/dist/auth/app_settings_schema.js +1 -1
- package/dist/auth/audit_emitter.d.ts +6 -7
- package/dist/auth/audit_emitter.d.ts.map +1 -1
- package/dist/auth/audit_emitter.js +11 -22
- package/dist/auth/audit_log_ddl.d.ts +1 -1
- package/dist/auth/audit_log_ddl.js +1 -1
- package/dist/auth/audit_log_queries.d.ts +0 -13
- package/dist/auth/audit_log_queries.d.ts.map +1 -1
- package/dist/auth/audit_log_queries.js +3 -3
- package/dist/auth/audit_log_route_schema.d.ts +1 -1
- package/dist/auth/audit_log_route_schema.js +1 -1
- package/dist/auth/audit_log_schema.d.ts +69 -70
- package/dist/auth/audit_log_schema.d.ts.map +1 -1
- package/dist/auth/audit_log_schema.js +2 -2
- package/dist/auth/auth_ddl.d.ts +1 -1
- package/dist/auth/auth_ddl.js +1 -1
- package/dist/auth/bootstrap_route_schema.d.ts +4 -4
- package/dist/auth/bootstrap_route_schema.js +1 -1
- package/dist/auth/cell_action_specs.d.ts +466 -466
- package/dist/auth/cell_action_specs.js +1 -1
- package/dist/auth/cell_actions.d.ts +2 -2
- package/dist/auth/cell_actions.js +5 -5
- package/dist/auth/cell_audit_action_specs.d.ts +14 -14
- package/dist/auth/cell_audit_action_specs.js +1 -1
- package/dist/auth/cell_audit_metadata.d.ts +8 -8
- package/dist/auth/cell_audit_metadata.js +1 -1
- package/dist/auth/cell_field_action_specs.d.ts +55 -55
- package/dist/auth/cell_field_action_specs.js +1 -1
- package/dist/auth/cell_field_audit_metadata.d.ts +4 -4
- package/dist/auth/cell_field_audit_metadata.js +1 -1
- package/dist/auth/cell_grant_action_specs.d.ts +61 -61
- package/dist/auth/cell_grant_action_specs.js +1 -1
- package/dist/auth/cell_grant_audit_metadata.d.ts +10 -10
- package/dist/auth/cell_grant_audit_metadata.js +1 -1
- package/dist/auth/cell_item_action_specs.d.ts +76 -76
- package/dist/auth/cell_item_action_specs.js +1 -1
- package/dist/auth/cell_item_audit_metadata.d.ts +5 -5
- package/dist/auth/cell_item_audit_metadata.js +1 -1
- package/dist/auth/invite_schema.d.ts +11 -11
- package/dist/auth/invite_schema.d.ts.map +1 -1
- package/dist/auth/invite_schema.js +1 -1
- package/dist/auth/name_schema.js +1 -1
- package/dist/auth/password.js +1 -1
- package/dist/auth/request_context.js +2 -2
- package/dist/auth/role_grant_offer_action_specs.d.ts +182 -182
- package/dist/auth/role_grant_offer_action_specs.js +1 -1
- package/dist/auth/role_grant_offer_ddl.d.ts +1 -1
- package/dist/auth/role_grant_offer_ddl.js +1 -1
- package/dist/auth/role_grant_offer_notifications.d.ts +107 -107
- package/dist/auth/role_grant_offer_notifications.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_notifications.js +3 -4
- package/dist/auth/role_grant_offer_schema.d.ts +9 -9
- package/dist/auth/role_grant_offer_schema.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_schema.js +1 -1
- package/dist/auth/self_service_role_action_specs.d.ts +2 -2
- package/dist/auth/self_service_role_action_specs.js +1 -1
- package/dist/auth/self_service_role_actions.d.ts +1 -1
- package/dist/auth/self_service_role_actions.js +1 -1
- package/dist/auth/signup_route_schema.d.ts +2 -2
- package/dist/auth/signup_route_schema.js +1 -1
- package/dist/auth/token_scope.d.ts +8 -8
- package/dist/db/file_fact_url.d.ts +1 -1
- package/dist/env/env_schemas.d.ts +1 -2
- package/dist/env/env_schemas.d.ts.map +1 -1
- package/dist/env/env_schemas.js +3 -4
- package/dist/http/CLAUDE.md +30 -32
- package/dist/http/auth_shape.d.ts +17 -52
- package/dist/http/auth_shape.d.ts.map +1 -1
- package/dist/http/auth_shape.js +19 -61
- package/dist/http/db_routes.d.ts +1 -1
- package/dist/http/db_routes.d.ts.map +1 -1
- package/dist/http/db_routes.js +1 -1
- package/dist/http/error_schemas.d.ts +36 -36
- package/dist/http/jsonrpc.d.ts +11 -11
- package/dist/http/jsonrpc_helpers.js +1 -1
- package/dist/http/route_error_check.d.ts +2 -2
- package/dist/http/route_error_check.d.ts.map +1 -1
- package/dist/http/route_error_check.js +2 -3
- package/dist/http/route_errors.d.ts +4 -4
- package/dist/http/route_errors.d.ts.map +1 -1
- package/dist/http/route_errors.js +0 -13
- package/dist/http/route_spec.d.ts +33 -36
- package/dist/http/route_spec.d.ts.map +1 -1
- package/dist/http/route_spec.js +21 -22
- package/dist/http/schema_helpers.d.ts +75 -67
- package/dist/http/schema_helpers.d.ts.map +1 -1
- package/dist/http/schema_helpers.js +54 -76
- package/dist/http/surface.d.ts.map +1 -1
- package/dist/http/surface.js +6 -8
- package/dist/primitive_schemas.d.ts +162 -112
- package/dist/primitive_schemas.d.ts.map +1 -1
- package/dist/primitive_schemas.js +129 -161
- package/dist/realtime/sse.d.ts +3 -3
- package/dist/realtime/sse.d.ts.map +1 -1
- package/dist/realtime/sse.js +2 -2
- package/dist/schema_issues.d.ts +41 -146
- package/dist/schema_issues.d.ts.map +1 -1
- package/dist/schema_issues.js +39 -322
- package/dist/schema_meta.d.ts +63 -136
- package/dist/schema_meta.d.ts.map +1 -1
- package/dist/schema_meta.js +37 -184
- package/dist/sensitivity.d.ts +3 -5
- package/dist/sensitivity.d.ts.map +1 -1
- package/dist/sensitivity.js +3 -5
- package/dist/server/serve_fact_route.js +1 -1
- package/dist/server/surface_route.js +1 -1
- package/dist/testing/CLAUDE.md +23 -25
- package/dist/testing/adversarial_headers.js +2 -2
- package/dist/testing/adversarial_input_cases.d.ts +19 -18
- package/dist/testing/adversarial_input_cases.d.ts.map +1 -1
- package/dist/testing/adversarial_input_cases.js +29 -42
- package/dist/testing/assertions.d.ts +2 -2
- package/dist/testing/assertions.d.ts.map +1 -1
- package/dist/testing/assertions.js +3 -3
- package/dist/testing/cross_backend/account_lifecycle.js +2 -2
- package/dist/testing/cross_backend/action_manifest.d.ts +10 -9
- package/dist/testing/cross_backend/action_manifest.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest.js +4 -3
- package/dist/testing/cross_backend/cell_crud.js +1 -1
- package/dist/testing/cross_backend/conformance_case.d.ts +96 -114
- package/dist/testing/cross_backend/conformance_case.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_case.js +0 -256
- package/dist/testing/cross_backend/conformance_rpc_auth.d.ts +0 -62
- package/dist/testing/cross_backend/conformance_rpc_auth.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_table.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_table.js +3 -3
- package/dist/testing/cross_backend/cross_rpc.d.ts +3 -4
- package/dist/testing/cross_backend/cross_rpc.d.ts.map +1 -1
- package/dist/testing/cross_backend/cross_rpc.js +4 -4
- package/dist/testing/cross_backend/differential.js +2 -2
- package/dist/testing/cross_backend/fact_serving.js +1 -1
- package/dist/testing/cross_backend/identity_parity.js +9 -9
- package/dist/testing/cross_backend/origin_conformance.d.ts +9 -9
- package/dist/testing/cross_backend/query_shape.js +1 -1
- package/dist/testing/cross_backend/rpc_success_fixtures.d.ts.map +1 -1
- package/dist/testing/cross_backend/rust_spine_consumer_surface.d.ts +1 -1
- package/dist/testing/cross_backend/setup.d.ts +26 -4
- package/dist/testing/cross_backend/setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/setup.js +7 -8
- package/dist/testing/cross_backend/sse_round_trip.js +2 -2
- package/dist/testing/cross_backend/testing_origin_check.d.ts +12 -12
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +608 -201
- package/dist/testing/cross_backend/testing_reset_actions.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.js +46 -55
- package/dist/testing/cross_backend/token_lifetime.js +3 -3
- package/dist/testing/cross_backend/wire_shapes.js +1 -1
- package/dist/testing/cross_backend/ws_outbound_overflow.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_outbound_overflow.js +35 -0
- package/dist/testing/cross_backend/ws_round_trip.js +1 -1
- package/dist/testing/data_exposure.d.ts.map +1 -1
- package/dist/testing/data_exposure.js +1 -1
- package/dist/testing/integration.js +2 -2
- package/dist/testing/integration_helpers.d.ts.map +1 -1
- package/dist/testing/integration_helpers.js +2 -2
- package/dist/testing/middleware.d.ts.map +1 -1
- package/dist/testing/middleware.js +2 -2
- package/dist/testing/rpc_attack_surface.js +1 -1
- package/dist/testing/rpc_envelope_cases.d.ts +3 -3
- package/dist/testing/rpc_envelope_cases.d.ts.map +1 -1
- package/dist/testing/rpc_envelope_cases.js +1 -1
- package/dist/testing/rpc_helpers.d.ts +12 -14
- package/dist/testing/rpc_helpers.d.ts.map +1 -1
- package/dist/testing/rpc_helpers.js +9 -11
- package/dist/testing/schema_generators.d.ts +67 -60
- package/dist/testing/schema_generators.d.ts.map +1 -1
- package/dist/testing/schema_generators.js +144 -151
- package/dist/testing/schema_introspect.d.ts +438 -78
- package/dist/testing/schema_introspect.d.ts.map +1 -1
- package/dist/testing/schema_introspect.js +26 -26
- package/dist/testing/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/sse_round_trip.js +2 -2
- package/dist/testing/surface_invariants.d.ts +1 -1
- package/dist/testing/surface_invariants.js +1 -1
- package/dist/testing/transports/bootstrap.d.ts +1 -1
- package/dist/testing/transports/bootstrap.d.ts.map +1 -1
- package/dist/testing/transports/bootstrap.js +1 -1
- package/dist/ui/BootstrapForm.svelte +1 -2
- package/dist/ui/BootstrapForm.svelte.d.ts.map +1 -1
- package/dist/ui/SignupForm.svelte +1 -2
- package/dist/ui/SignupForm.svelte.d.ts.map +1 -1
- package/dist/ui/admin_accounts_state.svelte.d.ts +5 -5
- package/dist/ui/admin_accounts_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_invites_state.svelte.d.ts +1 -1
- package/dist/ui/admin_invites_state.svelte.d.ts.map +1 -1
- package/dist/ui/admin_sessions_state.svelte.d.ts +2 -2
- package/dist/ui/admin_sessions_state.svelte.d.ts.map +1 -1
- package/dist/ui/form_state.svelte.d.ts +1 -1
- package/dist/ui/form_state.svelte.js +1 -1
- package/dist/ui/role_grant_offers_state.svelte.d.ts +1 -1
- package/package.json +7 -9
- package/dist/primitive_schemas_fuz.d.ts +0 -178
- package/dist/primitive_schemas_fuz.d.ts.map +0 -1
- package/dist/primitive_schemas_fuz.js +0 -149
- package/dist/zod.d.ts +0 -101
- package/dist/zod.d.ts.map +0 -1
- package/dist/zod.js +0 -195
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conformance_table.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/conformance_table.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"conformance_table.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/conformance_table.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA+C9B,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC7E,OAAO,KAAK,EAAe,SAAS,EAAE,MAAM,0BAA0B,CAAC;AACvE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAOnE,OAAO,EAMN,+BAA+B,EAC/B,KAAK,uBAAuB,EAC5B,MAAM,mBAAmB,CAAC;AAI3B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAGvE,OAAO,EAGN,KAAK,eAAe,EACpB,KAAK,oBAAoB,EACzB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAGzD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEzD;;;;;GAKG;AACH,MAAM,W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BAAsB,EAAE,UAAU,CAAC,OAAO,+BAA+B,CAAC,CAAC;IACpF,qFAAqF;IACrF,QAAQ,CAAC,EAAE,CAAC,EAAE,gBAAgB,CAAC;IAC/B;;;OAGG;IACH,QAAQ,CAAC,eAAe,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;CAC5D;AAED,4EAA4E;AAC5E,MAAM,MAAM,qBAAqB,GAC9B;IAAE,QAAQ,CAAC,IAAI,EAAE,KAAK,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAA;CAAE,GAC3E;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,KAAK,EAAE,SAAS,CAAA;CAAE,CAAC;AAExD;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,uBAAuB;IACvC,QAAQ,CAAC,MAAM,EAAE,qBAAqB,CAAC;IACvC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACzC,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;CACvB;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,qBAAqB,GACjC,GAAG,eAAe,EAClB,SAAS,0BAA0B,KACjC,OAAO,CAAC,uBAAuB,CAuFjC,CAAC;AA8NF;;;;;GAKG;AACH,eAAO,MAAM,gCAAgC,GAAI,SAAS,uBAAuB,KAAG,IAuEnF,CAAC"}
|
|
@@ -41,6 +41,7 @@ import '../assert_dev_env.js';
|
|
|
41
41
|
* @module
|
|
42
42
|
*/
|
|
43
43
|
import { assert, describe, test } from 'vitest';
|
|
44
|
+
import { parse } from '@fuzdev/fuz_schema/schema.ts';
|
|
44
45
|
import { DAEMON_TOKEN_HEADER } from '../../auth/daemon_token.js';
|
|
45
46
|
import { find_auth_route, rest_auth_route_suffixes } from '../integration_helpers.js';
|
|
46
47
|
import { find_rpc_action, headers_to_record, parse_rpc_call_result, rpc_call_raw, create_rpc_request_text, resolve_rpc_endpoints_for_setup } from '../rpc_helpers.js';
|
|
@@ -51,7 +52,6 @@ import { is_response_for } from '../transports/ws_client.js';
|
|
|
51
52
|
import { SCOPED_TOKEN_ADMITTED_METHOD } from './conformance_case.js';
|
|
52
53
|
import { mint_narrowed_api_token } from './narrowed_api_token.js';
|
|
53
54
|
import { xfail_until } from './xfail.js';
|
|
54
|
-
import { parse_any } from '../../schema_issues.js';
|
|
55
55
|
/**
|
|
56
56
|
* Resolve the endpoints a conformance case's RPC method is looked up in: the
|
|
57
57
|
* declared `rpc_endpoints`, then `live_rpc_endpoints`. `find_rpc_action`
|
|
@@ -588,7 +588,7 @@ const assert_rpc_case = (c, action, sent) => {
|
|
|
588
588
|
if (is_success_status(c.expect.status)) {
|
|
589
589
|
assert.ok(res.ok, `${c.name}: expected success (${c.expect.status}) but got error ${JSON.stringify(res.ok ? undefined : res.error)}`);
|
|
590
590
|
assert.strictEqual(res.status, c.expect.status, `${c.name}: status`);
|
|
591
|
-
const parsed =
|
|
591
|
+
const parsed = parse(action.spec.output, res.result);
|
|
592
592
|
assert.ok(parsed.ok, `${c.name}: result does not match spec.output: ${JSON.stringify(parsed.ok ? undefined : parsed.issues)}`);
|
|
593
593
|
if (c.expect.fields)
|
|
594
594
|
assert_fields(res.result, c.expect.fields, c.name);
|
|
@@ -616,7 +616,7 @@ const assert_rest_case = (c, route, sent) => {
|
|
|
616
616
|
const { status, body } = sent;
|
|
617
617
|
assert.strictEqual(status, c.expect.status, `${c.name}: status`);
|
|
618
618
|
if (is_success_status(c.expect.status)) {
|
|
619
|
-
const parsed =
|
|
619
|
+
const parsed = parse(route.output, body);
|
|
620
620
|
assert.ok(parsed.ok, `${c.name}: body does not match route output: ${JSON.stringify(parsed.ok ? undefined : parsed.issues)}`);
|
|
621
621
|
}
|
|
622
622
|
else if (c.expect.error_reason !== undefined) {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type
|
|
3
|
-
import type { Schema } from '@fuzdev/fuz_schema/schema.ts';
|
|
2
|
+
import { type Schema } from '@fuzdev/fuz_schema/schema.ts';
|
|
4
3
|
import type { FetchTransport } from '../transports/fetch_transport.js';
|
|
5
4
|
/** Minimal JSON-RPC envelope shape the suites read off responses. */
|
|
6
5
|
export interface RpcResult {
|
|
@@ -35,8 +34,8 @@ export declare const cross_rpc_call: (transport: FetchTransport, path: string, m
|
|
|
35
34
|
export declare const error_reason: (r: RpcResult) => unknown;
|
|
36
35
|
/**
|
|
37
36
|
* Assert the call succeeded and the `result` matches the verb's declared
|
|
38
|
-
* output schema
|
|
37
|
+
* output schema — the wire-shape parity gate.
|
|
39
38
|
* Returns the parsed output.
|
|
40
39
|
*/
|
|
41
|
-
export declare const expect_output: <T>(r: RpcResult, schema:
|
|
40
|
+
export declare const expect_output: <T>(r: RpcResult, schema: Schema<T, any>) => T;
|
|
42
41
|
//# sourceMappingURL=cross_rpc.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cross_rpc.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cross_rpc.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAgB9B,OAAO,
|
|
1
|
+
{"version":3,"file":"cross_rpc.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cross_rpc.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAgB9B,OAAO,EAAE,KAAK,MAAM,EAAS,MAAM,8BAA8B,CAAC;AAGlE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAEvE,qEAAqE;AACrE,MAAM,WAAW,SAAS;IACzB,yCAAyC;IACzC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,KAAK,CAAC,EAAE;QAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,OAAO,CAAA;KAAE,CAAC;CAC9F;AAKD;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,cAAc,GAC1B,WAAW,cAAc,EACzB,MAAM,MAAM,EACZ,QAAQ,MAAM,EACd,QAAQ,OAAO,EACf,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAC7B,OAAO,CAAC,SAAS,CAmBnB,CAAC;AAEF,gFAAgF;AAChF,eAAO,MAAM,YAAY,GAAI,GAAG,SAAS,KAAG,OAG/B,CAAC;AAEd;;;;GAIG;AACH,eAAO,MAAM,aAAa,GAAI,CAAC,EAAE,GAAG,SAAS,EAAE,QAAQ,MAAM,CAAC,CAAC,EAAE,GAAG,CAAC,KAAG,CAUvE,CAAC"}
|
|
@@ -5,15 +5,15 @@ import '../assert_dev_env.js';
|
|
|
5
5
|
* The stateful suites (the cell verbs, account lifecycle, role grants, tokens,
|
|
6
6
|
* facts, audit reads) POST raw JSON-RPC envelopes over a cross-process
|
|
7
7
|
* `FetchTransport`, threading ids and auth headers across calls, and parse
|
|
8
|
-
* every success `result` against the verb's declared
|
|
8
|
+
* every success `result` against the verb's declared **output** schema —
|
|
9
9
|
* the wire-shape parity gate. A TS↔Rust envelope drift, not just a payload
|
|
10
10
|
* field drift, fails the assertion.
|
|
11
11
|
*
|
|
12
12
|
* @module
|
|
13
13
|
*/
|
|
14
14
|
import { assert } from 'vitest';
|
|
15
|
+
import { parse } from '@fuzdev/fuz_schema/schema.ts';
|
|
15
16
|
import { create_rpc_post_init } from '../rpc_helpers.js';
|
|
16
|
-
import { parse_any } from '../../schema_issues.js';
|
|
17
17
|
/** How much of a non-envelope reply body `cross_rpc_call`'s error quotes. */
|
|
18
18
|
const BODY_HEAD_LENGTH = 200;
|
|
19
19
|
/**
|
|
@@ -57,12 +57,12 @@ export const error_reason = (r) => r.error && typeof r.error.data === 'object' &
|
|
|
57
57
|
: undefined;
|
|
58
58
|
/**
|
|
59
59
|
* Assert the call succeeded and the `result` matches the verb's declared
|
|
60
|
-
* output schema
|
|
60
|
+
* output schema — the wire-shape parity gate.
|
|
61
61
|
* Returns the parsed output.
|
|
62
62
|
*/
|
|
63
63
|
export const expect_output = (r, schema) => {
|
|
64
64
|
assert.ok(r.ok, `expected success, got ${JSON.stringify(r.error)}`);
|
|
65
|
-
const parsed =
|
|
65
|
+
const parsed = parse(schema, r.result);
|
|
66
66
|
assert.ok(parsed.ok, `result does not match output schema: ${parsed.ok ? '' : JSON.stringify(parsed.issues)} (got ${JSON.stringify(r.result)})`);
|
|
67
67
|
return parsed.value;
|
|
68
68
|
};
|
|
@@ -3,8 +3,8 @@ import '../assert_dev_env.js';
|
|
|
3
3
|
* The cross-backend differential: each impl is the oracle for the other.
|
|
4
4
|
*
|
|
5
5
|
* A conformance case pins its status and reason on one backend at a time,
|
|
6
|
-
* and an output schema is often loose (`
|
|
7
|
-
*
|
|
6
|
+
* and an output schema is often loose (a `loose_object` or a `strip_object`),
|
|
7
|
+
* so an extra field from one spine — possibly a leak — passes, as
|
|
8
8
|
* does any body difference on a case pinned by status alone.
|
|
9
9
|
* `describe_differential_conformance_tests` sends every case to two backends,
|
|
10
10
|
* normalizes both responses (`normalize_differential_response`), and asserts
|
|
@@ -60,7 +60,7 @@ import '../assert_dev_env.js';
|
|
|
60
60
|
import { describe, assert } from 'vitest';
|
|
61
61
|
import { object } from '@fuzdev/fuz_schema/schema.ts';
|
|
62
62
|
import { fact_hash_bytes } from '@fuzdev/fuz_util/fact_hash.ts';
|
|
63
|
-
import { FactHashSchema } from '../../
|
|
63
|
+
import { FactHashSchema } from '../../primitive_schemas.js';
|
|
64
64
|
import { CellCreateOutput } from '../../auth/cell_action_specs.js';
|
|
65
65
|
import { FACT_CACHE_CONTROL, FACT_CONTENT_SECURITY_POLICY, FACT_X_CONTENT_TYPE_OPTIONS } from '../../server/fact_security_headers.js';
|
|
66
66
|
import { test_if } from './capabilities.js';
|
|
@@ -46,7 +46,7 @@ import '../assert_dev_env.js';
|
|
|
46
46
|
* **Login input validation:** malformed login input → 400 `invalid_request_body`
|
|
47
47
|
* on every spine — whitespace-only username (empty after trim), over-long
|
|
48
48
|
* username (> 255), empty password, and an unknown body key (strict object).
|
|
49
|
-
* TS runs the full `LoginInput`
|
|
49
|
+
* TS runs the full `LoginInput` schema; the Rust spine enforces the same
|
|
50
50
|
* shape in `account_login` (the convergence the suite closed: the Rust spine
|
|
51
51
|
* previously let three of these fall through to a lookup-miss 401, and TS let a
|
|
52
52
|
* whitespace-only identifier through to a 401). Asserted via the error reason,
|
|
@@ -60,7 +60,7 @@ import '../assert_dev_env.js';
|
|
|
60
60
|
* **Length + format creation parity:** the full `Username` shape —
|
|
61
61
|
* `[USERNAME_LENGTH_MIN, USERNAME_LENGTH_MAX]` = `[3, 39]` and the regex
|
|
62
62
|
* `^[a-zA-Z][0-9a-zA-Z_-]*[0-9a-zA-Z]$` — pinned across both backends. The TS
|
|
63
|
-
*
|
|
63
|
+
* `Username` bounds and regex and the Rust hand-rolled byte-scan
|
|
64
64
|
* (`is_valid_username_for_creation`) are independent reimplementations of the
|
|
65
65
|
* same rule, so each length boundary is tested just-outside (→ 400) and
|
|
66
66
|
* just-inside (→ 403 no-matching-invite, the settle for a valid username on a
|
|
@@ -84,8 +84,8 @@ import '../assert_dev_env.js';
|
|
|
84
84
|
* edges, no whitespace — `White_Space ∪ {U+FEFF}` — plus a 254-byte (RFC 5321
|
|
85
85
|
* octet) length bound), Rust the hand-rolled `is_valid_email`. A malformed email → 400, a well-formed one →
|
|
86
86
|
* 403 no-matching-invite (the same accept/reject settle the username tables
|
|
87
|
-
* use). The accepted siblings include the single-char-TLD `a@b.c` that
|
|
88
|
-
*
|
|
87
|
+
* use). The accepted siblings include the single-char-TLD `a@b.c` that a
|
|
88
|
+
* stricter email grammar rejects — the deliberately-looser rule both spines
|
|
89
89
|
* share. This closed a real divergence: the Rust spine previously
|
|
90
90
|
* length-checked the email only, accepting any non-empty string TS rejected.
|
|
91
91
|
*
|
|
@@ -207,7 +207,7 @@ const USERNAME_FORMAT_CASES = [
|
|
|
207
207
|
* edge (beside another dot inside the domain too), surrounding whitespace,
|
|
208
208
|
* over the length bound — so a backend policing only one of them is caught.
|
|
209
209
|
* The accepted siblings are the don't-over-reject control and include the
|
|
210
|
-
* shapes
|
|
210
|
+
* shapes a stricter email grammar rejects but our looser rule accepts — single-char
|
|
211
211
|
* TLD `a@b.c` and consecutive dots `a..b@c.d` and `a@b..c` — pinning the
|
|
212
212
|
* deliberately-looser shared rule in both directions.
|
|
213
213
|
* Every case rides a valid username so the rejection (or the 403 no-invite
|
|
@@ -252,17 +252,17 @@ const SIGNUP_EMAIL_CASES = [
|
|
|
252
252
|
{ email: 'user@example.com', label: 'well-formed', status: VALID_USERNAME_NO_INVITE_STATUS },
|
|
253
253
|
{
|
|
254
254
|
email: 'a@b.c',
|
|
255
|
-
label: 'single-char TLD (looser
|
|
255
|
+
label: 'single-char TLD (the looser rule)',
|
|
256
256
|
status: VALID_USERNAME_NO_INVITE_STATUS
|
|
257
257
|
},
|
|
258
258
|
{
|
|
259
259
|
email: 'a..b@c.d',
|
|
260
|
-
label: 'consecutive dots (looser
|
|
260
|
+
label: 'consecutive dots (the looser rule)',
|
|
261
261
|
status: VALID_USERNAME_NO_INVITE_STATUS
|
|
262
262
|
},
|
|
263
263
|
{
|
|
264
264
|
email: 'user@example..com',
|
|
265
|
-
label: 'consecutive dots inside the domain (looser
|
|
265
|
+
label: 'consecutive dots inside the domain (the looser rule)',
|
|
266
266
|
status: VALID_USERNAME_NO_INVITE_STATUS
|
|
267
267
|
},
|
|
268
268
|
{
|
|
@@ -484,7 +484,7 @@ export const describe_identity_parity_cross_tests = (options) => {
|
|
|
484
484
|
// shape on both spines (TS `Email` regex + 254-byte bound, Rust `is_valid_email`):
|
|
485
485
|
// malformed → 400, well-formed → 403 no-invite. The username is fixed-valid so
|
|
486
486
|
// each case isolates the email; the `a@b.c` accept pins the deliberately
|
|
487
|
-
// looser
|
|
487
|
+
// looser rule both spines share.
|
|
488
488
|
describe('signup email format parity', () => {
|
|
489
489
|
for (const { email, label, status } of SIGNUP_EMAIL_CASES) {
|
|
490
490
|
test(`${label} → ${status}`, async () => {
|
|
@@ -89,13 +89,13 @@ export declare const OriginConformanceParseRow: import("@fuzdev/fuz_schema/schem
|
|
|
89
89
|
export type OriginConformanceParseRow = Infer<typeof OriginConformanceParseRow>;
|
|
90
90
|
/** A match row: a valid allowlist, one `Origin` value or `null`, and the answer. */
|
|
91
91
|
export declare const OriginConformanceMatchRow: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
92
|
-
origin: string | null;
|
|
93
92
|
patterns: string;
|
|
93
|
+
origin: string | null;
|
|
94
94
|
allowed: boolean;
|
|
95
95
|
note?: string | undefined;
|
|
96
96
|
}, {
|
|
97
|
-
origin: string | null;
|
|
98
97
|
patterns: string;
|
|
98
|
+
origin: string | null;
|
|
99
99
|
allowed: boolean;
|
|
100
100
|
note?: string | undefined;
|
|
101
101
|
}, "object", {
|
|
@@ -108,8 +108,8 @@ export type OriginConformanceMatchRow = Infer<typeof OriginConformanceMatchRow>;
|
|
|
108
108
|
/** The conformance table, a `@fuzdev/fuz_schema` `object`. */
|
|
109
109
|
export declare const OriginConformance: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
110
110
|
match: {
|
|
111
|
-
origin: string | null;
|
|
112
111
|
patterns: string;
|
|
112
|
+
origin: string | null;
|
|
113
113
|
allowed: boolean;
|
|
114
114
|
note?: string | undefined;
|
|
115
115
|
}[];
|
|
@@ -127,8 +127,8 @@ export declare const OriginConformance: import("@fuzdev/fuz_schema/schema.ts").S
|
|
|
127
127
|
})[];
|
|
128
128
|
}, {
|
|
129
129
|
match: {
|
|
130
|
-
origin: string | null;
|
|
131
130
|
patterns: string;
|
|
131
|
+
origin: string | null;
|
|
132
132
|
allowed: boolean;
|
|
133
133
|
note?: string | undefined;
|
|
134
134
|
}[];
|
|
@@ -250,28 +250,28 @@ export declare const OriginConformance: import("@fuzdev/fuz_schema/schema.ts").S
|
|
|
250
250
|
note: import("@fuzdev/fuz_schema/schema.ts").Schema<string | undefined, string | undefined, "optional", import("@fuzdev/fuz_schema/schema.ts").SchemaWrapperDef<import("@fuzdev/fuz_schema/schema.ts").Schema<string, string, "string", undefined>>>;
|
|
251
251
|
}>]>>>;
|
|
252
252
|
match: import("@fuzdev/fuz_schema/schema.ts").PipeSchema<{
|
|
253
|
-
origin: string | null;
|
|
254
253
|
patterns: string;
|
|
254
|
+
origin: string | null;
|
|
255
255
|
allowed: boolean;
|
|
256
256
|
note?: string | undefined;
|
|
257
257
|
}[], import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
258
|
-
origin: string | null;
|
|
259
258
|
patterns: string;
|
|
259
|
+
origin: string | null;
|
|
260
260
|
allowed: boolean;
|
|
261
261
|
note?: string | undefined;
|
|
262
262
|
}[], {
|
|
263
|
-
origin: string | null;
|
|
264
263
|
patterns: string;
|
|
264
|
+
origin: string | null;
|
|
265
265
|
allowed: boolean;
|
|
266
266
|
note?: string | undefined;
|
|
267
267
|
}[], "array", import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
268
|
-
origin: string | null;
|
|
269
268
|
patterns: string;
|
|
269
|
+
origin: string | null;
|
|
270
270
|
allowed: boolean;
|
|
271
271
|
note?: string | undefined;
|
|
272
272
|
}, {
|
|
273
|
-
origin: string | null;
|
|
274
273
|
patterns: string;
|
|
274
|
+
origin: string | null;
|
|
275
275
|
allowed: boolean;
|
|
276
276
|
note?: string | undefined;
|
|
277
277
|
}, "object", {
|
|
@@ -4,7 +4,7 @@ import '../assert_dev_env.js';
|
|
|
4
4
|
*
|
|
5
5
|
* The TS pipeline reads queries through Hono's `c.req.query()` — a duplicated
|
|
6
6
|
* key resolves to its **first** occurrence — and only routes that declare a
|
|
7
|
-
* `
|
|
7
|
+
* strict `object` query schema 400 unknown keys, in the pipeline's
|
|
8
8
|
* params → query → 401 → authz → 403 phase order. A derived-serde axum
|
|
9
9
|
* extractor diverges on every axis (a plain-text pre-handler "duplicate
|
|
10
10
|
* field" 400 observable anonymously, silently ignored unknown keys, query
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rpc_success_fixtures.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/rpc_success_fixtures.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAqC9B,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"rpc_success_fixtures.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/rpc_success_fixtures.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAqC9B,OAAO,KAAK,EAAqB,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAOlF,uDAAuD;AACvD,MAAM,WAAW,8BAA8B;IAC9C,gGAAgG;IAChG,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,iCAAiC,GAC7C,UAAS,8BAAmC,KAC1C,kBAwHF,CAAC"}
|
|
@@ -53,7 +53,7 @@ export interface RustSpineConsumerRpcEndpointsOptions {
|
|
|
53
53
|
readonly roles?: RoleRegistry;
|
|
54
54
|
/**
|
|
55
55
|
* Domain methods kept off the declared surface — ones the spec-derived
|
|
56
|
-
* suites can't drive (an input whose
|
|
56
|
+
* suites can't drive (an input whose `check` the generic body generator
|
|
57
57
|
* can't satisfy). They stay mounted on the backend; this only leaves them
|
|
58
58
|
* out of what the suites enumerate.
|
|
59
59
|
*/
|
|
@@ -1,6 +1,28 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Per-test fixture protocol shared by in-process and cross-process
|
|
4
|
+
* transports.
|
|
5
|
+
*
|
|
6
|
+
* Each standard suite body takes a required
|
|
7
|
+
* `setup_test: () => Promise<TestFixture>` callback and invokes it once
|
|
8
|
+
* per test. The fixture carries everything a test needs to fire requests
|
|
9
|
+
* and assert on a single bootstrapped keeper account — transport,
|
|
10
|
+
* account / actor identity, three header builders, a multi-account mint
|
|
11
|
+
* factory, and (in-process only) the in-memory keyring + raw backend.
|
|
12
|
+
*
|
|
13
|
+
* The cross-process producer `default_cross_process_setup` lives here,
|
|
14
|
+
* alongside the spawn-a-backend transport plumbing — it implements the
|
|
15
|
+
* `SetupTest` contract by spawning a binary and bootstrapping over real
|
|
16
|
+
* HTTP. The in-process producers (`default_in_process_setup` /
|
|
17
|
+
* `default_in_process_suite_options`, which wrap `create_test_app`) live
|
|
18
|
+
* in the sibling `in_process_setup.ts` so this module — and the
|
|
19
|
+
* cross-process consumers that import it — stay free of the in-process
|
|
20
|
+
* Hono app and its optional `hono` peer dependency.
|
|
21
|
+
*
|
|
22
|
+
* @module
|
|
23
|
+
*/
|
|
24
|
+
import { type Infer, type AnySchema } from '@fuzdev/fuz_schema/schema.ts';
|
|
25
|
+
import { Uuid } from '../../primitive_schemas.js';
|
|
4
26
|
import type { TestAccount } from '../app_server.js';
|
|
5
27
|
import type { BackendCapabilities } from './capabilities.js';
|
|
6
28
|
import { type FetchTransport } from '../transports/fetch_transport.js';
|
|
@@ -419,7 +441,7 @@ export declare const capture_schema_snapshot: (handle: ReconstructedBootstrapped
|
|
|
419
441
|
exclude_tables?: ReadonlyArray<string>;
|
|
420
442
|
}) => Promise<SchemaSnapshot>;
|
|
421
443
|
/**
|
|
422
|
-
* Parse a `capture_*` probe's answer with `schema
|
|
444
|
+
* Parse a `capture_*` probe's answer with `schema`: the
|
|
423
445
|
* parsed value, or a throw naming `method` with the issues, so a shape drift
|
|
424
446
|
* between the TS and Rust answers fails loud at the boundary.
|
|
425
447
|
*
|
|
@@ -429,7 +451,7 @@ export declare const capture_schema_snapshot: (handle: ReconstructedBootstrapped
|
|
|
429
451
|
* @returns the parsed answer, the schema's output
|
|
430
452
|
* @throws Error when `raw` fails `schema`
|
|
431
453
|
*/
|
|
432
|
-
export declare const parse_capture_answer: <T extends
|
|
454
|
+
export declare const parse_capture_answer: <T extends AnySchema>(method: string, schema: T, raw: unknown) => Infer<T>;
|
|
433
455
|
/**
|
|
434
456
|
* Capture a backend's live RPC action manifest over the
|
|
435
457
|
* `_testing_action_manifest` RPC action (keeper daemon-token channel). The
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/setup.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"setup.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/setup.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAMN,KAAK,KAAK,EACV,KAAK,SAAS,EACd,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAuB,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAKvE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,EAA0B,KAAK,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAC/F,OAAO,EAAE,gBAAgB,EAAE,KAAK,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,KAAK,EAAE,aAAa,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,EACvD,QAAQ,MAAM,EACd,QAAQ,CAAC,EACT,KAAK,OAAO,KACV,KAAK,CAAC,CAAC,CAMT,CAAC;AA8BF;;;;;;;;;GASG;AACH,eAAO,MAAM,uBAAuB,GACnC,QAAQ,sCAAsC,KAC5C,OAAO,CAAC,cAAc,CAC8C,CAAC;AAExE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,yBAAyB,GACrC,QAAQ,sCAAsC,KAC5C,OAAO,CAAC,gBAAgB,CACgD,CAAC;AAE5E;;;;;GAKG;AACH,eAAO,MAAM,8BAA8B,MAAM,CAAC;AAoVlD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,2BAA2B,GACvC,QAAQ,sCAAsC,EAC9C,UAAU,wBAAwB,KAChC,SAsIF,CAAC"}
|
|
@@ -22,9 +22,8 @@ import '../assert_dev_env.js';
|
|
|
22
22
|
* @module
|
|
23
23
|
*/
|
|
24
24
|
import { array, literal, parse, string, strip_object } from '@fuzdev/fuz_schema/schema.ts';
|
|
25
|
-
import { USERNAME_LENGTH_MAX } from '../../primitive_schemas.js';
|
|
26
|
-
import {
|
|
27
|
-
import { format_issues, parse_any } from '../../schema_issues.js';
|
|
25
|
+
import { USERNAME_LENGTH_MAX, Uuid } from '../../primitive_schemas.js';
|
|
26
|
+
import { format_issues } from '../../schema_issues.js';
|
|
28
27
|
import { DAEMON_TOKEN_HEADER } from '../../auth/daemon_token.js';
|
|
29
28
|
import { DEFAULT_TEST_PASSWORD } from '../test_credentials.js';
|
|
30
29
|
import { create_fetch_transport } from '../transports/fetch_transport.js';
|
|
@@ -180,14 +179,14 @@ const rpc_via_transport = async (transport, rpc_path, method, params, backend_na
|
|
|
180
179
|
*/
|
|
181
180
|
export const capture_schema_snapshot = async (handle, options = {}) => {
|
|
182
181
|
const raw = await rpc_via_transport(handle.keeper_daemon_transport, handle.config.rpc_path, '_testing_schema_snapshot', { exclude_tables: [...(options.exclude_tables ?? [])] }, handle.config.name, { [DAEMON_TOKEN_HEADER]: handle.daemon_token });
|
|
183
|
-
// TODO: cast, not parse — `
|
|
182
|
+
// TODO: cast, not parse — `parse(SchemaSnapshot, raw)` would validate the wire
|
|
184
183
|
// against the schema (the `capture_action_manifest` twin parses + uses a
|
|
185
184
|
// strict object); parsing here may surface a latent schema-model gap to
|
|
186
185
|
// reconcile first, so it's left as a follow-up.
|
|
187
186
|
return raw;
|
|
188
187
|
};
|
|
189
188
|
/**
|
|
190
|
-
* Parse a `capture_*` probe's answer with `schema
|
|
189
|
+
* Parse a `capture_*` probe's answer with `schema`: the
|
|
191
190
|
* parsed value, or a throw naming `method` with the issues, so a shape drift
|
|
192
191
|
* between the TS and Rust answers fails loud at the boundary.
|
|
193
192
|
*
|
|
@@ -198,7 +197,7 @@ export const capture_schema_snapshot = async (handle, options = {}) => {
|
|
|
198
197
|
* @throws Error when `raw` fails `schema`
|
|
199
198
|
*/
|
|
200
199
|
export const parse_capture_answer = (method, schema, raw) => {
|
|
201
|
-
const parsed =
|
|
200
|
+
const parsed = parse(schema, raw);
|
|
202
201
|
if (!parsed.ok) {
|
|
203
202
|
throw new Error(`${method}: the answer fails its schema:\n${format_issues(parsed.issues)}`);
|
|
204
203
|
}
|
|
@@ -206,13 +205,13 @@ export const parse_capture_answer = (method, schema, raw) => {
|
|
|
206
205
|
};
|
|
207
206
|
/**
|
|
208
207
|
* Capture a no-arg (void-input) daemon-token introspection RPC, sent with no
|
|
209
|
-
* params, and validate the wire response against `schema
|
|
208
|
+
* params, and validate the wire response against `schema`.
|
|
210
209
|
* The shared shape behind the parse-based `capture_*` cross-impl parity
|
|
211
210
|
* probes: call a `_testing_*` introspection action over the keeper's
|
|
212
211
|
* daemon-token channel, then `parse_capture_answer`.
|
|
213
212
|
*
|
|
214
213
|
* (`capture_schema_snapshot` deliberately stays separate: it *casts* rather
|
|
215
|
-
* than parses — narrowing a large snapshot to the
|
|
214
|
+
* than parses — narrowing a large snapshot to the schema model would silently
|
|
216
215
|
* drop unmodeled fields the parity diff should still see — and it takes an
|
|
217
216
|
* `exclude_tables` param.)
|
|
218
217
|
*/
|
|
@@ -59,12 +59,12 @@ import '../assert_dev_env.js';
|
|
|
59
59
|
* @module
|
|
60
60
|
*/
|
|
61
61
|
import { assert, describe } from 'vitest';
|
|
62
|
+
import { parse } from '@fuzdev/fuz_schema/schema.ts';
|
|
62
63
|
import { account_session_list_action_spec, account_session_revoke_action_spec, account_session_revoke_all_action_spec } from '../../auth/account_action_specs.js';
|
|
63
64
|
import { account_delete_action_spec, admin_session_revoke_all_action_spec } from '../../auth/admin_action_specs.js';
|
|
64
65
|
import { ROLE_ADMIN } from '../../auth/role_schema.js';
|
|
65
66
|
import { AUDIT_LOG_SSE_MAX_PER_SCOPE, audit_log_event_specs } from '../../realtime/audit_log_sse.js';
|
|
66
67
|
import { SSE_CONNECTED_COMMENT } from '../../realtime/sse_constants.js';
|
|
67
|
-
import { parse_any } from '../../schema_issues.js';
|
|
68
68
|
import { create_sse_transport } from '../transports/sse_transport.js';
|
|
69
69
|
import { create_rpc_post_init } from '../rpc_helpers.js';
|
|
70
70
|
import { DEFAULT_TEST_PASSWORD } from '../test_credentials.js';
|
|
@@ -83,7 +83,7 @@ const assert_audit_data_frame = (frame) => {
|
|
|
83
83
|
assert.strictEqual(typeof payload.method, 'string', 'audit data frame method must be a string');
|
|
84
84
|
const spec = audit_log_event_specs.find((s) => s.method === payload.method);
|
|
85
85
|
assert.ok(spec, `no EventSpec declared for audit method '${String(payload.method)}'`);
|
|
86
|
-
const result =
|
|
86
|
+
const result = parse(spec.params, payload.params);
|
|
87
87
|
assert.ok(result.ok, `audit data frame params mismatch for '${String(payload.method)}': ${result.ok ? '' : JSON.stringify(result.issues)}`);
|
|
88
88
|
};
|
|
89
89
|
/**
|
|
@@ -15,11 +15,11 @@ import { type Infer } from '@fuzdev/fuz_schema/schema.ts';
|
|
|
15
15
|
import { type RpcAction } from '../../actions/action_types.js';
|
|
16
16
|
/** Input of `_testing_origin_check`, a `@fuzdev/fuz_schema` `object`. */
|
|
17
17
|
export declare const TestingOriginCheckInput: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
18
|
-
origin: string | null;
|
|
19
18
|
patterns: string;
|
|
20
|
-
}, {
|
|
21
19
|
origin: string | null;
|
|
20
|
+
}, {
|
|
22
21
|
patterns: string;
|
|
22
|
+
origin: string | null;
|
|
23
23
|
}, "object", {
|
|
24
24
|
/** An allowlist value, as `FUZ_ALLOWED_ORIGINS` would carry it. */
|
|
25
25
|
patterns: import("@fuzdev/fuz_schema/schema.ts").Schema<string, string, "string", undefined>;
|
|
@@ -36,20 +36,20 @@ export declare const TestingOriginCheckOutput: import("@fuzdev/fuz_schema/schema
|
|
|
36
36
|
ok: true;
|
|
37
37
|
allowed: boolean;
|
|
38
38
|
} | {
|
|
39
|
+
ok: false;
|
|
39
40
|
errors: {
|
|
40
41
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
41
42
|
index?: number | undefined;
|
|
42
43
|
}[];
|
|
43
|
-
ok: false;
|
|
44
44
|
}, {
|
|
45
45
|
ok: true;
|
|
46
46
|
allowed: boolean;
|
|
47
47
|
} | {
|
|
48
|
+
ok: false;
|
|
48
49
|
errors: {
|
|
49
50
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
50
51
|
index?: number | undefined;
|
|
51
52
|
}[];
|
|
52
|
-
ok: false;
|
|
53
53
|
}, "union", readonly [import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
54
54
|
ok: true;
|
|
55
55
|
allowed: boolean;
|
|
@@ -60,17 +60,17 @@ export declare const TestingOriginCheckOutput: import("@fuzdev/fuz_schema/schema
|
|
|
60
60
|
ok: import("@fuzdev/fuz_schema/schema.ts").Schema<true, true, "literal", true>;
|
|
61
61
|
allowed: import("@fuzdev/fuz_schema/schema.ts").Schema<boolean, boolean, "boolean", undefined>;
|
|
62
62
|
}>, import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
63
|
+
ok: false;
|
|
63
64
|
errors: {
|
|
64
65
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
65
66
|
index?: number | undefined;
|
|
66
67
|
}[];
|
|
67
|
-
ok: false;
|
|
68
68
|
}, {
|
|
69
|
+
ok: false;
|
|
69
70
|
errors: {
|
|
70
71
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
71
72
|
index?: number | undefined;
|
|
72
73
|
}[];
|
|
73
|
-
ok: false;
|
|
74
74
|
}, "object", {
|
|
75
75
|
ok: import("@fuzdev/fuz_schema/schema.ts").Schema<false, false, "literal", false>;
|
|
76
76
|
errors: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
@@ -127,11 +127,11 @@ export declare const testing_origin_check_action_spec: {
|
|
|
127
127
|
};
|
|
128
128
|
readonly side_effects: false;
|
|
129
129
|
readonly input: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
130
|
-
origin: string | null;
|
|
131
130
|
patterns: string;
|
|
132
|
-
}, {
|
|
133
131
|
origin: string | null;
|
|
132
|
+
}, {
|
|
134
133
|
patterns: string;
|
|
134
|
+
origin: string | null;
|
|
135
135
|
}, "object", {
|
|
136
136
|
/** An allowlist value, as `FUZ_ALLOWED_ORIGINS` would carry it. */
|
|
137
137
|
patterns: import("@fuzdev/fuz_schema/schema.ts").Schema<string, string, "string", undefined>;
|
|
@@ -142,20 +142,20 @@ export declare const testing_origin_check_action_spec: {
|
|
|
142
142
|
ok: true;
|
|
143
143
|
allowed: boolean;
|
|
144
144
|
} | {
|
|
145
|
+
ok: false;
|
|
145
146
|
errors: {
|
|
146
147
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
147
148
|
index?: number | undefined;
|
|
148
149
|
}[];
|
|
149
|
-
ok: false;
|
|
150
150
|
}, {
|
|
151
151
|
ok: true;
|
|
152
152
|
allowed: boolean;
|
|
153
153
|
} | {
|
|
154
|
+
ok: false;
|
|
154
155
|
errors: {
|
|
155
156
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
156
157
|
index?: number | undefined;
|
|
157
158
|
}[];
|
|
158
|
-
ok: false;
|
|
159
159
|
}, "union", readonly [import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
160
160
|
ok: true;
|
|
161
161
|
allowed: boolean;
|
|
@@ -166,17 +166,17 @@ export declare const testing_origin_check_action_spec: {
|
|
|
166
166
|
ok: import("@fuzdev/fuz_schema/schema.ts").Schema<true, true, "literal", true>;
|
|
167
167
|
allowed: import("@fuzdev/fuz_schema/schema.ts").Schema<boolean, boolean, "boolean", undefined>;
|
|
168
168
|
}>, import("@fuzdev/fuz_schema/schema.ts").Schema<{
|
|
169
|
+
ok: false;
|
|
169
170
|
errors: {
|
|
170
171
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
171
172
|
index?: number | undefined;
|
|
172
173
|
}[];
|
|
173
|
-
ok: false;
|
|
174
174
|
}, {
|
|
175
|
+
ok: false;
|
|
175
176
|
errors: {
|
|
176
177
|
kind: "empty_entry" | "not_printable_ascii" | "missing_scheme" | "unsupported_scheme" | "has_path" | "has_userinfo" | "missing_host" | "invalid_host_char" | "unbracketed_ipv6" | "partial_wildcard" | "non_canonical_ipv4" | "unclosed_ipv6" | "invalid_ipv6" | "invalid_after_ipv6" | "invalid_port" | "default_port" | "no_origins";
|
|
177
178
|
index?: number | undefined;
|
|
178
179
|
}[];
|
|
179
|
-
ok: false;
|
|
180
180
|
}, "object", {
|
|
181
181
|
ok: import("@fuzdev/fuz_schema/schema.ts").Schema<false, false, "literal", false>;
|
|
182
182
|
errors: import("@fuzdev/fuz_schema/schema.ts").Schema<{
|