@fuzdev/fuz_app 0.111.0 → 0.113.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 +15 -11
- package/dist/actions/action_rpc.d.ts +1 -1
- package/dist/actions/action_rpc.d.ts.map +1 -1
- package/dist/actions/action_rpc.js +4 -6
- package/dist/actions/peer_ping.d.ts +8 -0
- package/dist/actions/peer_ping.d.ts.map +1 -1
- package/dist/actions/peer_ping.js +8 -0
- package/dist/actions/peer_request.d.ts +1 -1
- package/dist/actions/peer_request.js +1 -1
- package/dist/actions/perform_action.d.ts +16 -9
- package/dist/actions/perform_action.d.ts.map +1 -1
- package/dist/actions/perform_action.js +30 -21
- package/dist/actions/register_action_ws.d.ts +1 -1
- package/dist/actions/register_action_ws.d.ts.map +1 -1
- package/dist/actions/register_action_ws.js +88 -21
- package/dist/auth/CLAUDE.md +43 -8
- package/dist/auth/account_actions.d.ts.map +1 -1
- package/dist/auth/account_actions.js +10 -1
- package/dist/auth/account_queries.d.ts.map +1 -1
- package/dist/auth/account_queries.js +36 -16
- package/dist/auth/account_schema.d.ts +20 -0
- package/dist/auth/account_schema.d.ts.map +1 -1
- package/dist/auth/account_schema.js +22 -1
- package/dist/auth/actor_search_actions.d.ts +3 -3
- package/dist/auth/actor_search_actions.d.ts.map +1 -1
- package/dist/auth/actor_search_actions.js +10 -6
- package/dist/auth/api_token_queries.d.ts.map +1 -1
- package/dist/auth/api_token_queries.js +11 -5
- package/dist/auth/app_settings_queries.d.ts.map +1 -1
- package/dist/auth/app_settings_queries.js +6 -4
- package/dist/auth/audit_log_queries.d.ts +6 -0
- package/dist/auth/audit_log_queries.d.ts.map +1 -1
- package/dist/auth/audit_log_queries.js +11 -5
- package/dist/auth/audit_log_route_schema.d.ts.map +1 -1
- package/dist/auth/audit_log_route_schema.js +12 -1
- package/dist/auth/cell_actions.d.ts.map +1 -1
- package/dist/auth/cell_actions.js +3 -8
- package/dist/auth/cell_audit_actions.d.ts.map +1 -1
- package/dist/auth/cell_audit_actions.js +1 -1
- package/dist/auth/cell_field_actions.js +1 -1
- package/dist/auth/cell_grant_actions.js +1 -1
- package/dist/auth/cell_item_actions.js +1 -1
- package/dist/auth/invite_queries.d.ts.map +1 -1
- package/dist/auth/invite_queries.js +10 -8
- package/dist/auth/role_grant_offer_action_specs.d.ts +2 -1
- package/dist/auth/role_grant_offer_action_specs.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_action_specs.js +2 -1
- package/dist/auth/role_grant_offer_ddl.d.ts +11 -0
- package/dist/auth/role_grant_offer_ddl.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_ddl.js +20 -2
- package/dist/auth/role_grant_offer_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_queries.js +29 -15
- package/dist/auth/role_grant_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_queries.js +21 -7
- package/dist/auth/session_queries.d.ts.map +1 -1
- package/dist/auth/session_queries.js +9 -4
- package/dist/db/CLAUDE.md +21 -2
- package/dist/db/cell_audit_queries.js +2 -2
- package/dist/db/cell_field_queries.d.ts +1 -1
- package/dist/db/cell_field_queries.d.ts.map +1 -1
- package/dist/db/cell_field_queries.js +8 -6
- package/dist/db/cell_grant_queries.d.ts +1 -1
- package/dist/db/cell_grant_queries.d.ts.map +1 -1
- package/dist/db/cell_grant_queries.js +12 -10
- package/dist/db/cell_item_queries.d.ts +1 -1
- package/dist/db/cell_item_queries.d.ts.map +1 -1
- package/dist/db/cell_item_queries.js +9 -7
- package/dist/db/cell_queries.d.ts +3 -3
- package/dist/db/cell_queries.d.ts.map +1 -1
- package/dist/db/cell_queries.js +6 -4
- package/dist/db/fact_disk_storage.js +1 -1
- package/dist/db/fact_queries.d.ts.map +1 -1
- package/dist/db/fact_queries.js +9 -3
- package/dist/db/sql_columns.d.ts +80 -3
- package/dist/db/sql_columns.d.ts.map +1 -1
- package/dist/db/sql_columns.js +91 -4
- package/dist/http/CLAUDE.md +6 -4
- package/dist/http/auth_shape.d.ts +19 -6
- package/dist/http/auth_shape.d.ts.map +1 -1
- package/dist/http/auth_shape.js +19 -6
- package/dist/http/jsonrpc_helpers.d.ts +13 -0
- package/dist/http/jsonrpc_helpers.d.ts.map +1 -1
- package/dist/http/jsonrpc_helpers.js +13 -0
- package/dist/http/surface_query.d.ts +29 -4
- package/dist/http/surface_query.d.ts.map +1 -1
- package/dist/http/surface_query.js +30 -5
- package/dist/realtime/sse_auth_guard.d.ts +9 -3
- package/dist/realtime/sse_auth_guard.d.ts.map +1 -1
- package/dist/realtime/sse_auth_guard.js +9 -3
- package/dist/server/serve_fact_route.d.ts.map +1 -1
- package/dist/server/serve_fact_route.js +7 -2
- package/dist/testing/CLAUDE.md +54 -28
- package/dist/testing/admin_integration.d.ts +0 -3
- package/dist/testing/admin_integration.d.ts.map +1 -1
- package/dist/testing/admin_integration.js +0 -1
- package/dist/testing/adversarial_404.d.ts.map +1 -1
- package/dist/testing/adversarial_404.js +4 -1
- package/dist/testing/adversarial_input.d.ts.map +1 -1
- package/dist/testing/adversarial_input.js +5 -4
- package/dist/testing/app_server.d.ts +4 -3
- package/dist/testing/app_server.d.ts.map +1 -1
- package/dist/testing/app_server.js +11 -5
- package/dist/testing/attack_surface.d.ts +21 -2
- package/dist/testing/attack_surface.d.ts.map +1 -1
- package/dist/testing/attack_surface.js +78 -27
- package/dist/testing/audit_completeness.d.ts +0 -3
- package/dist/testing/audit_completeness.d.ts.map +1 -1
- package/dist/testing/audit_completeness.js +0 -1
- package/dist/testing/auth_apps.d.ts +34 -2
- package/dist/testing/auth_apps.d.ts.map +1 -1
- package/dist/testing/auth_apps.js +43 -7
- package/dist/testing/cross_backend/account_lifecycle.d.ts +5 -4
- package/dist/testing/cross_backend/account_lifecycle.d.ts.map +1 -1
- package/dist/testing/cross_backend/account_lifecycle.js +7 -0
- package/dist/testing/cross_backend/action_manifest.d.ts +19 -3
- package/dist/testing/cross_backend/action_manifest.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest.js +10 -4
- package/dist/testing/cross_backend/action_manifest_parity.d.ts +9 -3
- package/dist/testing/cross_backend/action_manifest_parity.d.ts.map +1 -1
- package/dist/testing/cross_backend/action_manifest_parity.js +6 -0
- package/dist/testing/cross_backend/actor_lookup.d.ts +3 -2
- package/dist/testing/cross_backend/actor_lookup.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size.d.ts +4 -2
- package/dist/testing/cross_backend/body_size.d.ts.map +1 -1
- package/dist/testing/cross_backend/body_size.js +1 -1
- package/dist/testing/cross_backend/cell_crud.d.ts +2 -2
- package/dist/testing/cross_backend/cell_crud.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_crud.js +10 -0
- package/dist/testing/cross_backend/cell_gated_create.d.ts +3 -3
- package/dist/testing/cross_backend/cell_gated_create.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_grant_role.d.ts +2 -2
- package/dist/testing/cross_backend/cell_grant_role.d.ts.map +1 -1
- package/dist/testing/cross_backend/cell_relations.d.ts +2 -2
- package/dist/testing/cross_backend/cell_relations.d.ts.map +1 -1
- package/dist/testing/cross_backend/fact_serving.d.ts +2 -2
- package/dist/testing/cross_backend/fact_serving.d.ts.map +1 -1
- package/dist/testing/cross_backend/make_cross_backend_project.d.ts +17 -2
- package/dist/testing/cross_backend/make_cross_backend_project.d.ts.map +1 -1
- package/dist/testing/cross_backend/make_cross_backend_project.js +23 -3
- package/dist/testing/cross_backend/origin.d.ts +4 -2
- package/dist/testing/cross_backend/origin.d.ts.map +1 -1
- package/dist/testing/cross_backend/origin.js +1 -1
- package/dist/testing/cross_backend/peer_ping_ws.d.ts.map +1 -1
- package/dist/testing/cross_backend/peer_ping_ws.js +11 -7
- package/dist/testing/cross_backend/query_shape.d.ts +6 -5
- package/dist/testing/cross_backend/query_shape.d.ts.map +1 -1
- package/dist/testing/cross_backend/ready.d.ts +2 -2
- package/dist/testing/cross_backend/ready.d.ts.map +1 -1
- package/dist/testing/cross_backend/role_grant_offer_enumeration.d.ts.map +1 -1
- package/dist/testing/cross_backend/role_grant_offer_enumeration.js +7 -1
- package/dist/testing/cross_backend/setup.d.ts +26 -6
- package/dist/testing/cross_backend/setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/standard.d.ts +5 -1
- package/dist/testing/cross_backend/standard.d.ts.map +1 -1
- package/dist/testing/cross_backend/standard.js +1 -5
- package/dist/testing/cross_backend/testing_backdoor.js +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +5 -0
- package/dist/testing/cross_backend/testing_reset_actions.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.js +3 -2
- package/dist/testing/cross_backend/token_lifetime.d.ts.map +1 -1
- package/dist/testing/cross_backend/token_lifetime.js +6 -0
- package/dist/testing/cross_backend/token_scope_surface.d.ts +2 -2
- package/dist/testing/cross_backend/token_scope_surface.d.ts.map +1 -1
- package/dist/testing/cross_backend/token_scope_surface.js +36 -7
- package/dist/testing/cross_backend/wire_shapes.d.ts +22 -0
- package/dist/testing/cross_backend/wire_shapes.d.ts.map +1 -0
- package/dist/testing/cross_backend/wire_shapes.js +41 -0
- package/dist/testing/data_exposure.d.ts +0 -3
- package/dist/testing/data_exposure.d.ts.map +1 -1
- package/dist/testing/data_exposure.js +0 -1
- package/dist/testing/db.d.ts +44 -7
- package/dist/testing/db.d.ts.map +1 -1
- package/dist/testing/db.js +62 -27
- package/dist/testing/integration.d.ts.map +1 -1
- package/dist/testing/integration.js +15 -2
- package/dist/testing/round_trip.d.ts +0 -3
- package/dist/testing/round_trip.d.ts.map +1 -1
- package/dist/testing/round_trip.js +0 -4
- package/dist/testing/rpc_attack_surface.js +2 -2
- package/dist/testing/rpc_round_trip.d.ts +0 -3
- package/dist/testing/rpc_round_trip.d.ts.map +1 -1
- package/dist/testing/rpc_round_trip.js +0 -1
- package/dist/testing/schema_generators.d.ts +15 -0
- package/dist/testing/schema_generators.d.ts.map +1 -1
- package/dist/testing/schema_generators.js +45 -11
- package/dist/testing/standard.d.ts +5 -1
- package/dist/testing/standard.d.ts.map +1 -1
- package/dist/testing/standard.js +2 -7
- package/dist/testing/surface_invariants.d.ts +7 -1
- package/dist/testing/surface_invariants.d.ts.map +1 -1
- package/dist/testing/surface_invariants.js +11 -5
- package/dist/timestamp.d.ts +58 -0
- package/dist/timestamp.d.ts.map +1 -0
- package/dist/timestamp.js +57 -0
- package/dist/ui/AdminAccounts.svelte +6 -4
- package/dist/ui/AdminAccounts.svelte.d.ts.map +1 -1
- package/dist/ui/AdminInvites.svelte +3 -3
- package/dist/ui/AdminInvites.svelte.d.ts.map +1 -1
- package/dist/ui/AdminOverview.svelte +10 -10
- package/dist/ui/AdminOverview.svelte.d.ts.map +1 -1
- package/dist/ui/AdminRoleGrantHistory.svelte +7 -7
- package/dist/ui/AdminRoleGrantHistory.svelte.d.ts.map +1 -1
- package/dist/ui/AdminSettings.svelte +1 -1
- package/dist/ui/RoleGrantOfferHistory.svelte +3 -1
- package/dist/ui/RoleGrantOfferHistory.svelte.d.ts.map +1 -1
- package/dist/ui/RoleGrantOfferInbox.svelte +4 -1
- package/dist/ui/RoleGrantOfferInbox.svelte.d.ts.map +1 -1
- package/dist/ui/SurfaceExplorer.svelte +33 -17
- package/dist/ui/SurfaceExplorer.svelte.d.ts.map +1 -1
- package/dist/ui/role_grant_offers_state.svelte.d.ts.map +1 -1
- package/dist/ui/role_grant_offers_state.svelte.js +6 -2
- package/package.json +10 -10
|
@@ -2,8 +2,9 @@ import '../assert_dev_env.js';
|
|
|
2
2
|
import type { RpcPathCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/**
|
|
4
4
|
* Options for the actor-lookup parity suite. The standard RPC-dispatched
|
|
5
|
-
* cross-suite shape (`setup_test` / `
|
|
6
|
-
*
|
|
5
|
+
* cross-suite shape (`setup_test` / `rpc_path`); aliases the shared
|
|
6
|
+
* `RpcPathCrossSuiteOptions` rather than minting a duplicate. No case here
|
|
7
|
+
* is capability-gated, so the flag bundle is not on the shape.
|
|
7
8
|
*/
|
|
8
9
|
export type ActorLookupCrossTestOptions = RpcPathCrossSuiteOptions;
|
|
9
10
|
export declare const describe_actor_lookup_cross_tests: (options: ActorLookupCrossTestOptions) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"actor_lookup.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/actor_lookup.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAqC9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D
|
|
1
|
+
{"version":3,"file":"actor_lookup.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/actor_lookup.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAqC9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D;;;;;GAKG;AACH,MAAM,MAAM,2BAA2B,GAAG,wBAAwB,CAAC;AASnE,eAAO,MAAM,iCAAiC,GAAI,SAAS,2BAA2B,KAAG,IAkDxF,CAAC"}
|
|
@@ -2,8 +2,10 @@ import '../assert_dev_env.js';
|
|
|
2
2
|
import type { RpcPathCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/**
|
|
4
4
|
* Options for the body-size parity suite — the standard RPC-dispatched
|
|
5
|
-
* cross-suite shape (`setup_test` / `
|
|
6
|
-
*
|
|
5
|
+
* cross-suite shape (`setup_test` / `rpc_path`); aliases the shared
|
|
6
|
+
* `RpcPathCrossSuiteOptions` rather than minting a duplicate. The limit is
|
|
7
|
+
* on every spine, so no case is capability-gated and the flag bundle is not
|
|
8
|
+
* on the shape.
|
|
7
9
|
*/
|
|
8
10
|
export type BodySizeCrossTestOptions = RpcPathCrossSuiteOptions;
|
|
9
11
|
export declare const describe_body_size_cross_tests: (options: BodySizeCrossTestOptions) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"body_size.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/body_size.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA6D9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D
|
|
1
|
+
{"version":3,"file":"body_size.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/body_size.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA6D9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D;;;;;;GAMG;AACH,MAAM,MAAM,wBAAwB,GAAG,wBAAwB,CAAC;AAmDhE,eAAO,MAAM,8BAA8B,GAAI,SAAS,wBAAwB,KAAG,IA0ClF,CAAC"}
|
|
@@ -39,7 +39,7 @@ import '../assert_dev_env.js';
|
|
|
39
39
|
* Like origin/payload rejection, this is middleware-level flat REST — not the
|
|
40
40
|
* JSON-RPC envelope the conformance-table runner expects — so it's an
|
|
41
41
|
* imperative suite, not a `conformance_table` row. Runs both legs via the
|
|
42
|
-
* shared `
|
|
42
|
+
* shared `setup_test` protocol: the in-process leg
|
|
43
43
|
* (`auth/body_size_parity.db.test.ts`, plain `gro test`) and the cross-process
|
|
44
44
|
* leg (`cross_backend/body_size.cross.test.ts`, the TS spine binaries + Rust
|
|
45
45
|
* `testing_spine_stub` over real HTTP). The body-size limit is on every spine,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const describe_cell_crud_cross_tests: (options:
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
|
+
export declare const describe_cell_crud_cross_tests: (options: RpcPathCapabilityGatedCrossSuiteOptions) => void;
|
|
4
4
|
//# sourceMappingURL=cell_crud.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_crud.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_crud.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"cell_crud.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_crud.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA4D9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,YAAY,CAAC;AAG1E,eAAO,MAAM,8BAA8B,GAC1C,SAAS,uCAAuC,KAC9C,IA+cF,CAAC"}
|
|
@@ -48,6 +48,7 @@ import { describe, assert } from 'vitest';
|
|
|
48
48
|
import { CellCreateOutput, CellDeleteOutput, CellGetOutput, CellListOutput, CellUpdateOutput } from '../../auth/cell_action_specs.js';
|
|
49
49
|
import { test_if } from './capabilities.js';
|
|
50
50
|
import { cross_rpc_call, error_reason, expect_output } from './cell_cross_helpers.js';
|
|
51
|
+
import { assert_iso8601_seconds, assert_iso8601_seconds_nullable } from './wire_shapes.js';
|
|
51
52
|
import { SPINE_RPC_PATH } from './spine_surface_constants.js';
|
|
52
53
|
export const describe_cell_crud_cross_tests = (options) => {
|
|
53
54
|
const { setup_test, capabilities } = options;
|
|
@@ -64,6 +65,12 @@ export const describe_cell_crud_cross_tests = (options) => {
|
|
|
64
65
|
assert.strictEqual(created.cell.created_by, owner.actor.id);
|
|
65
66
|
assert.strictEqual(created.cell.updated_by, null);
|
|
66
67
|
assert.strictEqual(created.cell.grant_count, 0);
|
|
68
|
+
// Byte-shape gate: `CellJson`'s `z.string()` accepts a millisecond
|
|
69
|
+
// stamp too, so `expect_output` alone can't tell the two spines
|
|
70
|
+
// apart on the timestamp columns.
|
|
71
|
+
assert_iso8601_seconds(created.cell.created_at, 'cell_create.created_at');
|
|
72
|
+
assert_iso8601_seconds_nullable(created.cell.updated_at, 'cell_create.updated_at');
|
|
73
|
+
assert_iso8601_seconds_nullable(created.cell.deleted_at, 'cell_create.deleted_at');
|
|
67
74
|
const cell_id = created.cell.id;
|
|
68
75
|
// get by id — full CellGetOutput envelope; relations empty in the first cut
|
|
69
76
|
const got = expect_output(await cross_rpc_call(t, rpc_path, 'cell_get', { id: cell_id }, owner_headers), CellGetOutput);
|
|
@@ -74,10 +81,13 @@ export const describe_cell_crud_cross_tests = (options) => {
|
|
|
74
81
|
assert.strictEqual(got.items_truncated, false);
|
|
75
82
|
assert.strictEqual(got.can_edit, true);
|
|
76
83
|
assert.strictEqual(got.can_grant, true); // owner is manage-tier
|
|
84
|
+
assert_iso8601_seconds(got.cell.created_at, 'cell_get.created_at');
|
|
85
|
+
assert_iso8601_seconds_nullable(got.cell.updated_at, 'cell_get.updated_at');
|
|
77
86
|
// update data + flip to public (owner is manage-tier, so visibility write is allowed)
|
|
78
87
|
const updated = expect_output(await cross_rpc_call(t, rpc_path, 'cell_update', { cell_id, data: { label: 'hi2' }, visibility: 'public' }, owner_headers), CellUpdateOutput);
|
|
79
88
|
assert.strictEqual(updated.cell.visibility, 'public');
|
|
80
89
|
assert.strictEqual(updated.cell.updated_by, owner.actor.id);
|
|
90
|
+
assert_iso8601_seconds(updated.cell.updated_at, 'cell_update.updated_at');
|
|
81
91
|
// list includes it
|
|
82
92
|
const listed = expect_output(await cross_rpc_call(t, rpc_path, 'cell_list', {}, owner_headers), CellListOutput);
|
|
83
93
|
assert.ok(listed.cells.some((c) => c.id === cell_id), 'owner cell_list omitted the cell');
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const describe_cell_gated_create_cross_tests: (options:
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
|
+
export declare const describe_cell_gated_create_cross_tests: (options: RpcPathCapabilityGatedCrossSuiteOptions) => void;
|
|
4
4
|
/**
|
|
5
5
|
* Cross-backend parity for the **`cell_moderate` verb** (the `pending →
|
|
6
6
|
* approved | rejected` transition) — root-authority-gated.
|
|
@@ -24,5 +24,5 @@ export declare const describe_cell_gated_create_cross_tests: (options: RpcPathCr
|
|
|
24
24
|
*
|
|
25
25
|
* `$lib`-free by contract (relative specifiers only).
|
|
26
26
|
*/
|
|
27
|
-
export declare const describe_cell_moderate_cross_tests: (options:
|
|
27
|
+
export declare const describe_cell_moderate_cross_tests: (options: RpcPathCapabilityGatedCrossSuiteOptions) => void;
|
|
28
28
|
//# sourceMappingURL=cell_gated_create.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_gated_create.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_gated_create.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAiD9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"cell_gated_create.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_gated_create.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAiD9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,YAAY,CAAC;AAkB1E,eAAO,MAAM,sCAAsC,GAClD,SAAS,uCAAuC,KAC9C,IAwPF,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,kCAAkC,GAC9C,SAAS,uCAAuC,KAC9C,IAwHF,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/** App role the holder is seeded with; matches the spine's registered role. */
|
|
4
4
|
export declare const CELL_EDITOR_ROLE = "cell_editor";
|
|
5
5
|
/** Username the fixture seeds (via `extra_accounts`) holding `CELL_EDITOR_ROLE`. */
|
|
6
6
|
export declare const CELL_ROLE_HOLDER_USERNAME = "cell_role_holder";
|
|
7
|
-
export declare const describe_cell_grant_role_cross_tests: (options:
|
|
7
|
+
export declare const describe_cell_grant_role_cross_tests: (options: RpcPathCapabilityGatedCrossSuiteOptions) => void;
|
|
8
8
|
//# sourceMappingURL=cell_grant_role.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_grant_role.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_grant_role.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAmD9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"cell_grant_role.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_grant_role.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAmD9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,YAAY,CAAC;AAG1E,+EAA+E;AAC/E,eAAO,MAAM,gBAAgB,gBAAyB,CAAC;AAEvD,oFAAoF;AACpF,eAAO,MAAM,yBAAyB,qBAAqB,CAAC;AAK5D,eAAO,MAAM,oCAAoC,GAChD,SAAS,uCAAuC,KAC9C,IAsOF,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
3
|
-
export declare const describe_cell_relations_cross_tests: (options:
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
|
+
export declare const describe_cell_relations_cross_tests: (options: RpcPathCapabilityGatedCrossSuiteOptions) => void;
|
|
4
4
|
//# sourceMappingURL=cell_relations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cell_relations.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_relations.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA4F9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"cell_relations.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/cell_relations.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA4F9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,YAAY,CAAC;AAsF1E,eAAO,MAAM,mCAAmC,GAC/C,SAAS,uCAAuC,KAC9C,IAi2BF,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions, SetupTest } from './setup.js';
|
|
3
3
|
/**
|
|
4
4
|
* The fact suite adds one optional knob to the shared cell options: a setup
|
|
5
5
|
* variant whose keeper carries a **second actor**. Only the multi-actor case
|
|
6
6
|
* needs it; the rest of the suite runs single-actor, so wiring it is opt-in.
|
|
7
7
|
* Omit it and the multi-actor case silently skips.
|
|
8
8
|
*/
|
|
9
|
-
export interface FactServingCrossTestOptions extends
|
|
9
|
+
export interface FactServingCrossTestOptions extends RpcPathCapabilityGatedCrossSuiteOptions {
|
|
10
10
|
readonly setup_test_multi_actor?: SetupTest;
|
|
11
11
|
}
|
|
12
12
|
export declare const describe_fact_serving_cross_tests: (options: FactServingCrossTestOptions) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fact_serving.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/fact_serving.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAiD9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"fact_serving.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/fact_serving.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAiD9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAErF;;;;;GAKG;AACH,MAAM,WAAW,2BAA4B,SAAQ,uCAAuC;IAC3F,QAAQ,CAAC,sBAAsB,CAAC,EAAE,SAAS,CAAC;CAC5C;AA8BD,eAAO,MAAM,iCAAiC,GAAI,SAAS,2BAA2B,KAAG,IAiOxF,CAAC"}
|
|
@@ -48,14 +48,27 @@ export interface CrossBackendProjectOptions {
|
|
|
48
48
|
readonly exclude?: ReadonlyArray<string>;
|
|
49
49
|
/** vitest `sequence.groupOrder`. Default: `3` (runs after unit + db). */
|
|
50
50
|
readonly group_order?: number;
|
|
51
|
+
/**
|
|
52
|
+
* Per-test timeout in ms. Default: `30_000` — see `DEFAULT_TEST_TIMEOUT`
|
|
53
|
+
* for why the 5 s vitest default does not fit a spawned-backend suite.
|
|
54
|
+
* Always emitted, so a consumer's root `testTimeout` never leaks in.
|
|
55
|
+
*/
|
|
56
|
+
readonly test_timeout?: number;
|
|
57
|
+
/**
|
|
58
|
+
* Per-hook timeout in ms for `beforeAll` / `afterAll` etc. Default:
|
|
59
|
+
* `30_000`. Always emitted, so a consumer's root `hookTimeout` never
|
|
60
|
+
* leaks in.
|
|
61
|
+
*/
|
|
62
|
+
readonly hook_timeout?: number;
|
|
51
63
|
}
|
|
52
64
|
/**
|
|
53
65
|
* Build a single cross-backend vitest project config. Spread the results
|
|
54
66
|
* into `test.projects` in the consumer's `vite.config.ts`. `isolate: false`
|
|
55
67
|
* + `fileParallelism: false` because a project shares one spawned backend
|
|
56
|
-
* across its files
|
|
68
|
+
* across its files, and `testTimeout` / `hookTimeout` are always emitted so
|
|
69
|
+
* a spawned-backend case is never held to vitest's 5 s / 10 s defaults.
|
|
57
70
|
*/
|
|
58
|
-
export declare const make_cross_backend_project: ({ name, global_setup, include, exclude, group_order }: CrossBackendProjectOptions) => {
|
|
71
|
+
export declare const make_cross_backend_project: ({ name, global_setup, include, exclude, group_order, test_timeout, hook_timeout }: CrossBackendProjectOptions) => {
|
|
59
72
|
extends: true;
|
|
60
73
|
test: {
|
|
61
74
|
name: string;
|
|
@@ -67,6 +80,8 @@ export declare const make_cross_backend_project: ({ name, global_setup, include,
|
|
|
67
80
|
sequence: {
|
|
68
81
|
groupOrder: number;
|
|
69
82
|
};
|
|
83
|
+
testTimeout: number;
|
|
84
|
+
hookTimeout: number;
|
|
70
85
|
};
|
|
71
86
|
};
|
|
72
87
|
//# sourceMappingURL=make_cross_backend_project.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"make_cross_backend_project.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/make_cross_backend_project.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;
|
|
1
|
+
{"version":3,"file":"make_cross_backend_project.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/make_cross_backend_project.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AA2BH,MAAM,WAAW,0BAA0B;IAC1C;;;;;OAKG;IACH,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;;;;OAKG;IACH,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,8EAA8E;IAC9E,QAAQ,CAAC,OAAO,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACzC,6FAA6F;IAC7F,QAAQ,CAAC,OAAO,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACzC,yEAAyE;IACzE,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B;;;;OAIG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;IAC/B;;;;OAIG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED;;;;;;GAMG;AACH,eAAO,MAAM,0BAA0B,GAAI,mFAQxC,0BAA0B,KAAG;IAC/B,OAAO,EAAE,IAAI,CAAC;IACd,IAAI,EAAE;QACL,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QACvB,OAAO,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QACvB,WAAW,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QAC3B,OAAO,EAAE,KAAK,CAAC;QACf,eAAe,EAAE,KAAK,CAAC;QACvB,QAAQ,EAAE;YAAE,UAAU,EAAE,MAAM,CAAA;SAAE,CAAC;QACjC,WAAW,EAAE,MAAM,CAAC;QACpB,WAAW,EAAE,MAAM,CAAC;KACpB,CAAC;CAcD,CAAC"}
|
|
@@ -31,13 +31,31 @@
|
|
|
31
31
|
const DEFAULT_INCLUDE = ['src/test/cross_backend/*.cross.test.ts'];
|
|
32
32
|
/** vitest `sequence.groupOrder` for cross-backend projects — after unit (1) + db (2). */
|
|
33
33
|
const DEFAULT_GROUP_ORDER = 3;
|
|
34
|
+
/**
|
|
35
|
+
* Per-test timeout (ms). vitest's 5 s default is far too tight here: a
|
|
36
|
+
* cross-backend case talks to a spawned backend over a real socket and most
|
|
37
|
+
* begin with a full `_testing_reset` (truncate + reseed the auth tables,
|
|
38
|
+
* mint a session), which alone can outlast 5 s on a cold pool or a loaded
|
|
39
|
+
* machine. 30 s is the ecosystem's convention for backend-spawning suites —
|
|
40
|
+
* long enough that no honest case flakes, short enough that a hung socket
|
|
41
|
+
* still fails the run rather than stalling CI.
|
|
42
|
+
*/
|
|
43
|
+
const DEFAULT_TEST_TIMEOUT = 30_000;
|
|
44
|
+
/**
|
|
45
|
+
* Per-hook timeout (ms). `beforeAll` / `afterAll` in these suites do the
|
|
46
|
+
* heaviest work in the project — bootstrap fixtures, seeded accounts, file
|
|
47
|
+
* uploads — so hooks get the same 30 s budget as tests rather than vitest's
|
|
48
|
+
* 10 s default.
|
|
49
|
+
*/
|
|
50
|
+
const DEFAULT_HOOK_TIMEOUT = 30_000;
|
|
34
51
|
/**
|
|
35
52
|
* Build a single cross-backend vitest project config. Spread the results
|
|
36
53
|
* into `test.projects` in the consumer's `vite.config.ts`. `isolate: false`
|
|
37
54
|
* + `fileParallelism: false` because a project shares one spawned backend
|
|
38
|
-
* across its files
|
|
55
|
+
* across its files, and `testTimeout` / `hookTimeout` are always emitted so
|
|
56
|
+
* a spawned-backend case is never held to vitest's 5 s / 10 s defaults.
|
|
39
57
|
*/
|
|
40
|
-
export const make_cross_backend_project = ({ name, global_setup, include = DEFAULT_INCLUDE, exclude = [], group_order = DEFAULT_GROUP_ORDER }) => ({
|
|
58
|
+
export const make_cross_backend_project = ({ name, global_setup, include = DEFAULT_INCLUDE, exclude = [], group_order = DEFAULT_GROUP_ORDER, test_timeout = DEFAULT_TEST_TIMEOUT, hook_timeout = DEFAULT_HOOK_TIMEOUT }) => ({
|
|
41
59
|
extends: true,
|
|
42
60
|
test: {
|
|
43
61
|
name,
|
|
@@ -46,6 +64,8 @@ export const make_cross_backend_project = ({ name, global_setup, include = DEFAU
|
|
|
46
64
|
globalSetup: [global_setup],
|
|
47
65
|
isolate: false,
|
|
48
66
|
fileParallelism: false,
|
|
49
|
-
sequence: { groupOrder: group_order }
|
|
67
|
+
sequence: { groupOrder: group_order },
|
|
68
|
+
testTimeout: test_timeout,
|
|
69
|
+
hookTimeout: hook_timeout
|
|
50
70
|
}
|
|
51
71
|
});
|
|
@@ -2,8 +2,10 @@ import '../assert_dev_env.js';
|
|
|
2
2
|
import type { RpcPathCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/**
|
|
4
4
|
* Options for the origin parity suite. The standard RPC-dispatched
|
|
5
|
-
* cross-suite shape (`setup_test` / `
|
|
6
|
-
*
|
|
5
|
+
* cross-suite shape (`setup_test` / `rpc_path`); aliases the shared
|
|
6
|
+
* `RpcPathCrossSuiteOptions` rather than minting a duplicate. Origin
|
|
7
|
+
* middleware is on every spine, so no case is capability-gated and the flag
|
|
8
|
+
* bundle is not on the shape.
|
|
7
9
|
*/
|
|
8
10
|
export type OriginCrossTestOptions = RpcPathCrossSuiteOptions;
|
|
9
11
|
export declare const describe_origin_cross_tests: (options: OriginCrossTestOptions) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"origin.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/origin.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkC9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D
|
|
1
|
+
{"version":3,"file":"origin.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/origin.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkC9B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAG3D;;;;;;GAMG;AACH,MAAM,MAAM,sBAAsB,GAAG,wBAAwB,CAAC;AAM9D,eAAO,MAAM,2BAA2B,GAAI,SAAS,sBAAsB,KAAG,IAwC7E,CAAC"}
|
|
@@ -15,7 +15,7 @@ import '../assert_dev_env.js';
|
|
|
15
15
|
* clients (curl, CLI, server-to-server) carry no `Origin` and must not be
|
|
16
16
|
* blocked; token auth is the control for those callers.
|
|
17
17
|
*
|
|
18
|
-
* Runs both legs via the shared `
|
|
18
|
+
* Runs both legs via the shared `setup_test` protocol: the
|
|
19
19
|
* in-process leg (`auth/origin_parity.db.test.ts`, plain `gro test`) and the
|
|
20
20
|
* cross-process leg (`cross_backend/origin.cross.test.ts`, the TS spine
|
|
21
21
|
* binaries + Rust `testing_spine_stub` over real HTTP). Origin middleware is
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"peer_ping_ws.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/peer_ping_ws.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkD9B,OAAO,EAAE,KAAK,mBAAmB,EAAW,MAAM,mBAAmB,CAAC;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"peer_ping_ws.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/peer_ping_ws.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkD9B,OAAO,EAAE,KAAK,mBAAmB,EAAW,MAAM,mBAAmB,CAAC;AACtE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAuB5C,6DAA6D;AAC7D,MAAM,WAAW,qBAAqB;IACrC,8EAA8E;IAC9E,QAAQ,CAAC,UAAU,EAAE,SAAS,CAAC;IAC/B,iFAAiF;IACjF,QAAQ,CAAC,YAAY,EAAE,mBAAmB,CAAC;IAC3C,2EAA2E;IAC3E,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,+DAA+D;IAC/D,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CACzB;AAED;;;;;;GAMG;AACH,eAAO,MAAM,2BAA2B,GAAI,SAAS,qBAAqB,KAAG,IAwN5E,CAAC"}
|
|
@@ -40,16 +40,20 @@ import { create_ws_transport } from '../transports/ws_transport.js';
|
|
|
40
40
|
import { is_response_for } from '../transports/ws_client.js';
|
|
41
41
|
import { create_jsonrpc_request, is_jsonrpc_request } from '../../http/jsonrpc_helpers.js';
|
|
42
42
|
import { test_if } from './capabilities.js';
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
// The wire literals below are deliberate independent copies of the
|
|
44
|
+
// producers' constants (`actions/peer_ping.ts` on TS, `REASON_PEER_*` /
|
|
45
|
+
// `PEER_PING_METHOD` on Rust) — parity by test, not codegen. The harness
|
|
46
|
+
// asserts the bytes on the wire, so importing the producer would make a
|
|
47
|
+
// renamed-value regression invisible on both sides at once. Names track the
|
|
48
|
+
// producers'.
|
|
45
49
|
/** Wire method (both directions). Mirrors the Rust `PEER_PING_METHOD`. */
|
|
46
50
|
const PEER_PING_METHOD = 'peer/ping';
|
|
47
|
-
|
|
48
|
-
// as an independent TS-side copy of the Rust `REASON_PEER_*` constants
|
|
49
|
-
// (parity by test, not codegen).
|
|
51
|
+
/** Stable `data.reason` discriminators — the cross-impl wire contract. */
|
|
50
52
|
const REASON_PEER_TIMEOUT = 'peer_timeout';
|
|
51
|
-
const
|
|
53
|
+
const REASON_PEER_PING_INVALID_REPLY = 'peer_ping_invalid_reply';
|
|
52
54
|
const REASON_PEER_NO_TRANSPORT = 'peer_no_transport';
|
|
55
|
+
/** JSON-RPC endpoint path — matches the spine's `/api/rpc` (and the forge's). */
|
|
56
|
+
const RPC_PATH = '/api/rpc';
|
|
53
57
|
/** A reply payload that satisfies the Rust `PingResponse` shape. */
|
|
54
58
|
const valid_reply = (nonce) => ({ nonce, protocol_version: 1 });
|
|
55
59
|
/**
|
|
@@ -126,7 +130,7 @@ export const describe_peer_ping_ws_tests = (options) => {
|
|
|
126
130
|
try {
|
|
127
131
|
const frame = await ping_raw(ws, 3, { nonce: 1, timeout_ms: 2000 });
|
|
128
132
|
assert.ok('error' in frame, 'a malformed reply must error, not return garbage');
|
|
129
|
-
assert.strictEqual(error_reason(frame),
|
|
133
|
+
assert.strictEqual(error_reason(frame), REASON_PEER_PING_INVALID_REPLY);
|
|
130
134
|
}
|
|
131
135
|
finally {
|
|
132
136
|
await ws.close();
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { RpcPathCapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/**
|
|
4
|
-
* Options for the query-shape parity suite. The standard
|
|
5
|
-
* cross-suite shape (`setup_test` / `capabilities` /
|
|
6
|
-
*
|
|
4
|
+
* Options for the query-shape parity suite. The standard capability-gating
|
|
5
|
+
* RPC-dispatched cross-suite shape (`setup_test` / `capabilities` /
|
|
6
|
+
* `rpc_path`); aliases the shared `RpcPathCapabilityGatedCrossSuiteOptions`
|
|
7
|
+
* rather than minting a duplicate.
|
|
7
8
|
*/
|
|
8
|
-
export type QueryShapeCrossTestOptions =
|
|
9
|
+
export type QueryShapeCrossTestOptions = RpcPathCapabilityGatedCrossSuiteOptions;
|
|
9
10
|
export declare const describe_query_shape_cross_tests: (options: QueryShapeCrossTestOptions) => void;
|
|
10
11
|
//# sourceMappingURL=query_shape.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query_shape.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/query_shape.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA0C9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"query_shape.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/query_shape.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA0C9B,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,YAAY,CAAC;AAG1E;;;;;GAKG;AACH,MAAM,MAAM,0BAA0B,GAAG,uCAAuC,CAAC;AAQjF,eAAO,MAAM,gCAAgC,GAAI,SAAS,0BAA0B,KAAG,IAwHtF,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
|
-
import type {
|
|
2
|
+
import type { CapabilityGatedCrossSuiteOptions } from './setup.js';
|
|
3
3
|
/** Options for the readiness-probe parity suite. */
|
|
4
|
-
export interface ReadyCrossTestOptions extends
|
|
4
|
+
export interface ReadyCrossTestOptions extends CapabilityGatedCrossSuiteOptions {
|
|
5
5
|
/** Readiness probe path. Default `/ready`. */
|
|
6
6
|
readonly ready_path?: string;
|
|
7
7
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ready.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/ready.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkC9B,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"ready.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/ready.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAkC9B,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,YAAY,CAAC;AAEnE,oDAAoD;AACpD,MAAM,WAAW,qBAAsB,SAAQ,gCAAgC;IAC9E,8CAA8C;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,0BAA0B,GAAI,SAAS,qBAAqB,KAAG,IAuB3E,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"role_grant_offer_enumeration.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/role_grant_offer_enumeration.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"role_grant_offer_enumeration.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/role_grant_offer_enumeration.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAwD9B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AAK5C;;;;;;;;GAQG;AACH,eAAO,MAAM,sBAAsB,kBAAkB,CAAC;AAEtD,sDAAsD;AACtD,MAAM,WAAW,yCAAyC;IACzD;;;;;OAKG;IACH,QAAQ,CAAC,UAAU,EAAE,SAAS,CAAC;IAC/B,6CAA6C;IAC7C,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;CAC3B;AAQD,eAAO,MAAM,iDAAiD,GAC7D,SAAS,yCAAyC,KAChD,IAqGF,CAAC"}
|
|
@@ -46,6 +46,7 @@ import { describe, test, assert } from 'vitest';
|
|
|
46
46
|
import { rpc_call } from '../rpc_helpers.js';
|
|
47
47
|
import { ROLE_ADMIN } from '../../auth/role_schema.js';
|
|
48
48
|
import { ERROR_ROLE_GRANT_OFFER_ACTOR_MISMATCH, ERROR_ROLE_GRANT_OFFER_NOT_FOUND } from '../../auth/role_grant_offer_action_specs.js';
|
|
49
|
+
import { assert_iso8601_seconds } from './wire_shapes.js';
|
|
49
50
|
import { SPINE_RPC_PATH } from './spine_surface_constants.js';
|
|
50
51
|
/** A well-formed UUID that never names a real offer — exercises the not-found arm. */
|
|
51
52
|
const NIL_UUID = '00000000-0000-0000-0000-000000000000';
|
|
@@ -84,7 +85,12 @@ export const describe_role_grant_offer_enumeration_cross_tests = (options) => {
|
|
|
84
85
|
// Offer ROLE_ADMIN to the keeper's account, TARGETED at actor A.
|
|
85
86
|
const created = await rpc(fixture.fresh_transport(), 'role_grant_offer_create', { to_account_id: fixture.account.id, to_actor_id: target_actor.id, role: ROLE_ADMIN }, grantor.create_session_headers());
|
|
86
87
|
assert.ok(created.ok, `offer create must succeed: ${JSON.stringify(created)}`);
|
|
87
|
-
const
|
|
88
|
+
const offer = created.result.offer;
|
|
89
|
+
// Byte-shape gate on the offer's server-minted timestamps — a
|
|
90
|
+
// millisecond stamp parses the same but is a wire divergence.
|
|
91
|
+
assert_iso8601_seconds(offer.created_at, 'offer.created_at');
|
|
92
|
+
assert_iso8601_seconds(offer.expires_at, 'offer.expires_at');
|
|
93
|
+
const offer_id = offer.id;
|
|
88
94
|
// Sibling actor B (same account) tries to accept A's offer → 403
|
|
89
95
|
// actor_mismatch. The offer stays pending (no mutation on the denial).
|
|
90
96
|
const sibling_accept = await rpc(fixture.transport, 'role_grant_offer_accept', { offer_id, acting: sibling.id }, fixture.create_session_headers());
|
|
@@ -217,16 +217,27 @@ export type SetupTest = () => Promise<TestFixture>;
|
|
|
217
217
|
* Base options shared by every imperative cross-backend parity suite
|
|
218
218
|
* (`origin` / `ready` / `body_size` / `cell_*` / `actor_*` /
|
|
219
219
|
* `account_lifecycle` / `app_settings` / `testing_backdoor` / …). The
|
|
220
|
-
* `
|
|
221
|
-
*
|
|
222
|
-
*
|
|
223
|
-
*
|
|
224
|
-
*
|
|
225
|
-
*
|
|
220
|
+
* `setup_test` core is identical across them; each suite extends this with
|
|
221
|
+
* its own path field (`rpc_path` for RPC-dispatched suites via
|
|
222
|
+
* `RpcPathCrossSuiteOptions`, `ready_path` for the readiness probe, etc.),
|
|
223
|
+
* and a suite that actually gates cases on a capability flag extends
|
|
224
|
+
* `CapabilityGatedCrossSuiteOptions` instead. Lives here in the neutral
|
|
225
|
+
* fixture-types home rather than in any one domain helper, so a non-cell
|
|
226
|
+
* suite never reaches into the cell helpers for its option shape.
|
|
226
227
|
*/
|
|
227
228
|
export interface CrossSuiteOptions {
|
|
228
229
|
/** Per-test fixture-producing function (fresh keeper + db per call). */
|
|
229
230
|
readonly setup_test: SetupTest;
|
|
231
|
+
}
|
|
232
|
+
/**
|
|
233
|
+
* `CrossSuiteOptions` for a suite that reads capability flags — the ones
|
|
234
|
+
* whose cases are `test_if`-gated on a per-backend declaration. The field is
|
|
235
|
+
* on this variant rather than the base so a suite's option type states
|
|
236
|
+
* whether it consults capabilities: a caller cannot pass a flag bundle to a
|
|
237
|
+
* suite that ignores it, and a suite cannot quietly stop reading one while
|
|
238
|
+
* still demanding it.
|
|
239
|
+
*/
|
|
240
|
+
export interface CapabilityGatedCrossSuiteOptions extends CrossSuiteOptions {
|
|
230
241
|
/** Backend capability declarations — each suite gates on its own flag. */
|
|
231
242
|
readonly capabilities: BackendCapabilities;
|
|
232
243
|
}
|
|
@@ -241,6 +252,15 @@ export interface RpcPathCrossSuiteOptions extends CrossSuiteOptions {
|
|
|
241
252
|
/** RPC endpoint path the methods are mounted on. Default `/api/rpc`. */
|
|
242
253
|
readonly rpc_path?: string;
|
|
243
254
|
}
|
|
255
|
+
/**
|
|
256
|
+
* The RPC-dispatched shape for a capability-gating suite — the intersection
|
|
257
|
+
* of `RpcPathCrossSuiteOptions` and `CapabilityGatedCrossSuiteOptions`, and
|
|
258
|
+
* the most common option shape among the imperative cross suites (every
|
|
259
|
+
* `cell_*` suite, `query_shape`, `token_scope_surface`, `fact_serving`,
|
|
260
|
+
* `account_lifecycle`).
|
|
261
|
+
*/
|
|
262
|
+
export interface RpcPathCapabilityGatedCrossSuiteOptions extends RpcPathCrossSuiteOptions, CapabilityGatedCrossSuiteOptions {
|
|
263
|
+
}
|
|
244
264
|
/**
|
|
245
265
|
* Cross-process backend handle enriched with the bootstrapped keeper's
|
|
246
266
|
* captured credentials. Consumers compose this in vitest's
|
|
@@ -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;AA0B9B,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAK9C,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,EAAE,MAAM,oBAAoB,CAAC;AAExD;;;;;GAKG;AACH,MAAM,WAAW,wBAAwB;IACxC,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;IACjC,QAAQ,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAC/B;;;;;;;OAOG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;;;;;GAMG;AACH,MAAM,MAAM,kBAAkB,GAAG,WAAW,CAAC;AAE7C;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,gBAAgB;IAChC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;IACjC,QAAQ,CAAC,KAAK,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;CACtC;AAED,sEAAsE;AACtE,MAAM,WAAW,mBAAmB;IACnC,QAAQ,CAAC,OAAO,EAAE;Q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KG;AACH,eAAO,MAAM,8BAA8B,MAAM,CAAC;AA2UlD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,2BAA2B,GACvC,QAAQ,sCAAsC,EAC9C,UAAU,wBAAwB,KAChC,SA8IF,CAAC"}
|
|
@@ -59,7 +59,11 @@ export interface StandardCrossProcessTestOptions {
|
|
|
59
59
|
* in-process and cross-process tests.
|
|
60
60
|
*/
|
|
61
61
|
surface_source: AppSurfaceSpec;
|
|
62
|
-
/**
|
|
62
|
+
/**
|
|
63
|
+
* Backend capability declarations. Forwarded to the one bundled suite
|
|
64
|
+
* that gates on them (`describe_standard_integration_tests`); the other
|
|
65
|
+
* suites in the bundle read no flags and take no capability field.
|
|
66
|
+
*/
|
|
63
67
|
capabilities: BackendCapabilities;
|
|
64
68
|
/** Session config — needed for cookie_name + factory-form rpc_endpoints resolution. */
|
|
65
69
|
session_options: SessionOptions<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"standard.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/standard.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAClE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAM5D,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,mBAAmB,CAAC;AACjE,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAC7D,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzD;;;;;;GAMG;AACH,MAAM,WAAW,+BAA+B;IAC/C,2CAA2C;IAC3C,UAAU,EAAE,SAAS,CAAC;IAC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AC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC;IAC/F;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,GAAG,CAC1B,MAAM,EACN,CAAC,OAAO,EAAE,WAAW,KAAK,OAAO,CAAC;QAAE,GAAG,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC,CACnF,CAAC;CACF;AAED;;;;GAIG;AACH,eAAO,MAAM,qCAAqC,GACjD,SAAS,+BAA+B,KACtC,IAoCF,CAAC"}
|
|
@@ -21,28 +21,24 @@ export const describe_standard_cross_process_tests = (options) => {
|
|
|
21
21
|
describe_round_trip_validation({
|
|
22
22
|
setup_test: options.setup_test,
|
|
23
23
|
surface_source: options.surface_source,
|
|
24
|
-
capabilities: options.capabilities,
|
|
25
24
|
skip_routes: options.round_trip_skip_routes,
|
|
26
25
|
success_fixtures: options.rest_success_fixtures
|
|
27
26
|
});
|
|
28
27
|
describe_rpc_round_trip_tests({
|
|
29
28
|
setup_test: options.setup_test,
|
|
30
29
|
surface_source: options.surface_source,
|
|
31
|
-
capabilities: options.capabilities,
|
|
32
30
|
session_options: options.session_options,
|
|
33
31
|
rpc_endpoints: options.rpc_endpoints,
|
|
34
32
|
success_fixtures: options.rpc_success_fixtures
|
|
35
33
|
});
|
|
36
34
|
describe_data_exposure_tests({
|
|
37
35
|
setup_test: options.setup_test,
|
|
38
|
-
surface_source: options.surface_source
|
|
39
|
-
capabilities: options.capabilities
|
|
36
|
+
surface_source: options.surface_source
|
|
40
37
|
});
|
|
41
38
|
if (options.roles) {
|
|
42
39
|
describe_standard_admin_integration_tests({
|
|
43
40
|
setup_test: options.setup_test,
|
|
44
41
|
surface_source: options.surface_source,
|
|
45
|
-
capabilities: options.capabilities,
|
|
46
42
|
session_options: options.session_options,
|
|
47
43
|
roles: options.roles,
|
|
48
44
|
rpc_endpoints: options.rpc_endpoints,
|
|
@@ -30,7 +30,7 @@ import '../assert_dev_env.js';
|
|
|
30
30
|
*
|
|
31
31
|
* Each method is sent with **valid** params so each case varies only the
|
|
32
32
|
* credential. (Validation runs after the gates — the order is 401 → authz →
|
|
33
|
-
* 403 → 400 — so the shapes are belt-and-suspenders here rather than load-
|
|
33
|
+
* 403 → 429 → 400 — so the shapes are belt-and-suspenders here rather than load-
|
|
34
34
|
* bearing.) The handler never runs (the gate refuses first), so the writes
|
|
35
35
|
* never execute.
|
|
36
36
|
*
|
|
@@ -428,6 +428,11 @@ export declare const testing_action_manifest_action_spec: {
|
|
|
428
428
|
}>;
|
|
429
429
|
roles: z.ZodArray<z.ZodString>;
|
|
430
430
|
credential_types: z.ZodArray<z.ZodString>;
|
|
431
|
+
rate_limit: z.ZodNullable<z.ZodEnum<{
|
|
432
|
+
account: "account";
|
|
433
|
+
ip: "ip";
|
|
434
|
+
both: "both";
|
|
435
|
+
}>>;
|
|
431
436
|
}, z.core.$strict>>;
|
|
432
437
|
}, z.core.$strict>;
|
|
433
438
|
readonly async: true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"testing_reset_actions.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/testing_reset_actions.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoEG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,OAAO,EAAc,KAAK,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAKzE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AAqCzC;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;QAiBpC;;;;;;;;WAQG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWyC,CAAC;AAE/C;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,iCAAiC;;;;;;;;;;;;;;;;CAWA,CAAC;AAE/C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;CAwBC,CAAC;AAE/C;;;;;;GAMG;AACH,eAAO,MAAM,mCAAmC,QAAO,SACmB,CAAC;AAE3E;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;CAeK,CAAC;AAE/C;;;;;;;;;GASG;AACH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWF,CAAC;AAE/C;;;;GAIG;AACH,eAAO,MAAM,qCAAqC,QAAO,SAGvD,CAAC;AAEH;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,qCAAqC;;;;;;;;;;;;;;;;;;;;CAYJ,CAAC;AAE/C;;;;GAIG;AACH,eAAO,MAAM,uCAAuC,QAAO,SAGzD,CAAC;AAEH;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,mCAAmC
|
|
1
|
+
{"version":3,"file":"testing_reset_actions.d.ts","sourceRoot":"../src/lib/","sources":["../../../src/lib/testing/cross_backend/testing_reset_actions.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoEG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,OAAO,EAAc,KAAK,SAAS,EAAE,MAAM,6BAA6B,CAAC;AAKzE,OA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F,CAAC;AAEF,4CAA4C;AAC5C,MAAM,WAAW,2BAA2B;IAC3C;;;;;OAKG;IACH,QAAQ,CAAC,eAAe,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC;IACjD;;;;;OAKG;IACH,QAAQ,CAAC,kBAAkB,EAAE,gBAAgB,CAAC;IAC9C;;;;;;;;;;;OAWG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,CAAC,EAAE,EAAE,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;CACxD;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,sBAAsB,GAClC,MAAM,OAAO,EACb,SAAS,2BAA2B,KAClC,KAAK,CAAC,SAAS,CAsIjB,CAAC;AAEF,0FAA0F;AAC1F,eAAO,MAAM,0BAA0B,UAAmC,CAAC"}
|
|
@@ -368,8 +368,9 @@ export const testing_action_manifest_action_spec = {
|
|
|
368
368
|
input: z.strictObject({}),
|
|
369
369
|
output: ActionManifest,
|
|
370
370
|
async: true,
|
|
371
|
-
description: 'Test-binary only — dump the live RPC registry as a normalized
|
|
372
|
-
'manifest for cross-impl method-set +
|
|
371
|
+
description: 'Test-binary only — dump the live RPC registry as a normalized ' +
|
|
372
|
+
'{method, auth, side_effects, rate_limit} manifest for cross-impl method-set + ' +
|
|
373
|
+
'auth-shape parity diffing.'
|
|
373
374
|
};
|
|
374
375
|
/**
|
|
375
376
|
* Build the `_testing_action_manifest` action over a backend's full live RPC
|