@fuzdev/fuz_app 0.180.0 → 0.182.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 +38 -20
- package/dist/actions/action_rpc.d.ts +25 -6
- package/dist/actions/action_rpc.d.ts.map +1 -1
- package/dist/actions/action_rpc.js +56 -48
- package/dist/actions/action_types.d.ts +31 -13
- package/dist/actions/action_types.d.ts.map +1 -1
- package/dist/actions/action_types.js +1 -1
- package/dist/actions/notification_sender.d.ts +83 -0
- package/dist/actions/notification_sender.d.ts.map +1 -0
- package/dist/actions/notification_sender.js +85 -0
- package/dist/actions/perform_action.d.ts +13 -4
- package/dist/actions/perform_action.d.ts.map +1 -1
- package/dist/actions/perform_action.js +27 -18
- package/dist/actions/register_action_ws.d.ts +20 -2
- package/dist/actions/register_action_ws.d.ts.map +1 -1
- package/dist/actions/register_action_ws.js +17 -5
- package/dist/actions/ws_socket_session.d.ts +3 -0
- package/dist/actions/ws_socket_session.d.ts.map +1 -1
- package/dist/actions/ws_socket_session.js +3 -2
- package/dist/auth/CLAUDE.md +84 -59
- package/dist/auth/account_actions.d.ts.map +1 -1
- package/dist/auth/account_actions.js +30 -3
- package/dist/auth/account_queries.d.ts +213 -2
- package/dist/auth/account_queries.d.ts.map +1 -1
- package/dist/auth/account_queries.js +255 -2
- package/dist/auth/account_route_schema.d.ts +26 -16
- package/dist/auth/account_route_schema.d.ts.map +1 -1
- package/dist/auth/account_route_schema.js +10 -24
- package/dist/auth/account_routes.d.ts +5 -7
- package/dist/auth/account_routes.d.ts.map +1 -1
- package/dist/auth/account_routes.js +110 -89
- package/dist/auth/admin_actions.d.ts.map +1 -1
- package/dist/auth/admin_actions.js +117 -25
- package/dist/auth/api_token_queries.d.ts +29 -12
- package/dist/auth/api_token_queries.d.ts.map +1 -1
- package/dist/auth/api_token_queries.js +42 -27
- package/dist/auth/audit_log_route_schema.d.ts +1 -1
- package/dist/auth/audit_log_route_schema.d.ts.map +1 -1
- package/dist/auth/audit_log_routes.d.ts +1 -1
- package/dist/auth/audit_log_routes.d.ts.map +1 -1
- package/dist/auth/audit_log_routes.js +10 -12
- package/dist/auth/audit_log_schema.js +4 -4
- package/dist/auth/bearer_auth.d.ts +4 -3
- package/dist/auth/bearer_auth.d.ts.map +1 -1
- package/dist/auth/bearer_auth.js +37 -32
- package/dist/auth/bootstrap_account.d.ts +65 -37
- package/dist/auth/bootstrap_account.d.ts.map +1 -1
- package/dist/auth/bootstrap_account.js +115 -66
- package/dist/auth/bootstrap_route_schema.d.ts +6 -2
- package/dist/auth/bootstrap_route_schema.d.ts.map +1 -1
- package/dist/auth/bootstrap_route_schema.js +7 -2
- package/dist/auth/bootstrap_routes.d.ts +50 -33
- package/dist/auth/bootstrap_routes.d.ts.map +1 -1
- package/dist/auth/bootstrap_routes.js +109 -87
- package/dist/auth/bootstrap_token_store.d.ts +60 -0
- package/dist/auth/bootstrap_token_store.d.ts.map +1 -0
- package/dist/auth/bootstrap_token_store.js +39 -0
- package/dist/auth/credential_headers.d.ts +71 -0
- package/dist/auth/credential_headers.d.ts.map +1 -0
- package/dist/auth/credential_headers.js +100 -0
- package/dist/auth/daemon_token.d.ts +13 -1
- package/dist/auth/daemon_token.d.ts.map +1 -1
- package/dist/auth/daemon_token.js +14 -2
- package/dist/auth/daemon_token_middleware.d.ts +10 -11
- package/dist/auth/daemon_token_middleware.d.ts.map +1 -1
- package/dist/auth/daemon_token_middleware.js +39 -30
- package/dist/auth/deps.d.ts +10 -11
- package/dist/auth/deps.d.ts.map +1 -1
- package/dist/auth/invite_queries.d.ts +18 -0
- package/dist/auth/invite_queries.d.ts.map +1 -1
- package/dist/auth/invite_queries.js +24 -0
- package/dist/auth/request_context.d.ts +97 -76
- package/dist/auth/request_context.d.ts.map +1 -1
- package/dist/auth/request_context.js +93 -104
- package/dist/auth/resolved_auth.d.ts +10 -5
- package/dist/auth/resolved_auth.d.ts.map +1 -1
- package/dist/auth/resolved_auth.js +2 -2
- package/dist/auth/role_grant_offer_action_specs.d.ts +2 -2
- package/dist/auth/role_grant_offer_action_specs.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_action_specs.js +5 -3
- package/dist/auth/role_grant_offer_actions.d.ts +7 -11
- package/dist/auth/role_grant_offer_actions.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_actions.js +97 -106
- package/dist/auth/role_grant_offer_ddl.d.ts +7 -1
- package/dist/auth/role_grant_offer_ddl.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_ddl.js +9 -2
- package/dist/auth/role_grant_offer_notifications.d.ts +87 -38
- package/dist/auth/role_grant_offer_notifications.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_notifications.js +75 -22
- package/dist/auth/role_grant_offer_queries.d.ts +143 -9
- package/dist/auth/role_grant_offer_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_offer_queries.js +266 -66
- package/dist/auth/role_grant_offer_schema.js +1 -1
- package/dist/auth/role_grant_queries.d.ts +57 -10
- package/dist/auth/role_grant_queries.d.ts.map +1 -1
- package/dist/auth/role_grant_queries.js +81 -22
- package/dist/auth/role_grant_sql.d.ts +21 -0
- package/dist/auth/role_grant_sql.d.ts.map +1 -1
- package/dist/auth/role_grant_sql.js +21 -0
- package/dist/auth/self_service_role_actions.d.ts.map +1 -1
- package/dist/auth/self_service_role_actions.js +9 -2
- package/dist/auth/session_cookie.d.ts +105 -25
- package/dist/auth/session_cookie.d.ts.map +1 -1
- package/dist/auth/session_cookie.js +124 -15
- package/dist/auth/session_middleware.d.ts +83 -54
- package/dist/auth/session_middleware.d.ts.map +1 -1
- package/dist/auth/session_middleware.js +92 -66
- package/dist/auth/session_queries.d.ts +95 -14
- package/dist/auth/session_queries.d.ts.map +1 -1
- package/dist/auth/session_queries.js +98 -19
- package/dist/auth/signup_route_schema.d.ts +5 -5
- package/dist/auth/signup_route_schema.d.ts.map +1 -1
- package/dist/auth/signup_route_schema.js +4 -4
- package/dist/auth/signup_routes.d.ts.map +1 -1
- package/dist/auth/signup_routes.js +17 -14
- package/dist/auth/standard_rpc_actions.d.ts +6 -19
- package/dist/auth/standard_rpc_actions.d.ts.map +1 -1
- package/dist/auth/standard_rpc_actions.js +5 -6
- package/dist/auth/token_scope.d.ts +6 -8
- package/dist/auth/token_scope.d.ts.map +1 -1
- package/dist/auth/token_scope.js +6 -9
- package/dist/dev/setup.d.ts +6 -1
- package/dist/dev/setup.d.ts.map +1 -1
- package/dist/dev/setup.js +42 -34
- package/dist/hono_context.d.ts +21 -0
- package/dist/hono_context.d.ts.map +1 -1
- package/dist/hono_context.js +17 -0
- package/dist/http/CLAUDE.md +156 -48
- package/dist/http/auth_shape.d.ts +4 -4
- package/dist/http/common_routes.js +1 -1
- package/dist/http/db_routes.d.ts +4 -3
- package/dist/http/db_routes.d.ts.map +1 -1
- package/dist/http/db_routes.js +14 -14
- package/dist/http/dev_route_error_check.d.ts +6 -3
- package/dist/http/dev_route_error_check.d.ts.map +1 -1
- package/dist/http/dev_route_error_check.js +6 -3
- package/dist/http/dev_set_cookie_check.d.ts +53 -0
- package/dist/http/dev_set_cookie_check.d.ts.map +1 -0
- package/dist/http/dev_set_cookie_check.js +80 -0
- package/dist/http/error_schemas.d.ts +45 -22
- package/dist/http/error_schemas.d.ts.map +1 -1
- package/dist/http/error_schemas.js +53 -26
- package/dist/http/header_lines.d.ts +42 -0
- package/dist/http/header_lines.d.ts.map +1 -0
- package/dist/http/header_lines.js +80 -0
- package/dist/http/host.d.ts +12 -9
- package/dist/http/host.d.ts.map +1 -1
- package/dist/http/host.js +25 -20
- package/dist/http/origin.d.ts +7 -22
- package/dist/http/origin.d.ts.map +1 -1
- package/dist/http/origin.js +11 -25
- package/dist/http/proxy.d.ts +1 -0
- package/dist/http/proxy.d.ts.map +1 -1
- package/dist/http/proxy.js +3 -0
- package/dist/http/request_headers.d.ts +95 -0
- package/dist/http/request_headers.d.ts.map +1 -0
- package/dist/http/request_headers.js +110 -0
- package/dist/http/request_target.d.ts +134 -0
- package/dist/http/request_target.d.ts.map +1 -0
- package/dist/http/request_target.js +193 -0
- package/dist/http/route_error_check.d.ts +4 -11
- package/dist/http/route_error_check.d.ts.map +1 -1
- package/dist/http/route_error_check.js +4 -21
- package/dist/http/route_result.d.ts +127 -23
- package/dist/http/route_result.d.ts.map +1 -1
- package/dist/http/route_result.js +97 -19
- package/dist/http/route_spec.d.ts +299 -83
- package/dist/http/route_spec.d.ts.map +1 -1
- package/dist/http/route_spec.js +548 -71
- package/dist/http/simple_request.d.ts +19 -14
- package/dist/http/simple_request.d.ts.map +1 -1
- package/dist/http/simple_request.js +17 -29
- package/dist/http/surface.d.ts +2 -0
- package/dist/http/surface.d.ts.map +1 -1
- package/dist/http/surface.js +4 -1
- package/dist/realtime/outbound_budget.d.ts +1 -2
- package/dist/realtime/outbound_budget.d.ts.map +1 -1
- package/dist/realtime/outbound_budget.js +1 -2
- package/dist/realtime/sse.d.ts +47 -17
- package/dist/realtime/sse.d.ts.map +1 -1
- package/dist/realtime/sse.js +115 -93
- package/dist/realtime/sse_constants.d.ts +7 -1
- package/dist/realtime/sse_constants.d.ts.map +1 -1
- package/dist/realtime/sse_constants.js +12 -1
- package/dist/realtime/sse_registry.d.ts +3 -3
- package/dist/realtime/sse_registry.js +3 -3
- package/dist/runtime/deps.d.ts +20 -4
- package/dist/runtime/deps.d.ts.map +1 -1
- package/dist/runtime/mock.d.ts +7 -1
- package/dist/runtime/mock.d.ts.map +1 -1
- package/dist/runtime/mock.js +33 -3
- package/dist/runtime/node.d.ts.map +1 -1
- package/dist/runtime/node.js +2 -1
- package/dist/runtime/secure_file.d.ts +71 -10
- package/dist/runtime/secure_file.d.ts.map +1 -1
- package/dist/runtime/secure_file.js +91 -11
- package/dist/server/app_backend.d.ts +0 -8
- package/dist/server/app_backend.d.ts.map +1 -1
- package/dist/server/app_backend.js +4 -4
- package/dist/server/app_server.d.ts +54 -33
- package/dist/server/app_server.d.ts.map +1 -1
- package/dist/server/app_server.js +69 -41
- package/dist/server/serve_fact_route.d.ts +3 -3
- package/dist/server/serve_fact_route.d.ts.map +1 -1
- package/dist/server/serve_fact_route.js +59 -55
- package/dist/server/static.d.ts +20 -0
- package/dist/server/static.d.ts.map +1 -1
- package/dist/server/static.js +56 -8
- package/dist/server/unmatched_route.d.ts +42 -0
- package/dist/server/unmatched_route.d.ts.map +1 -0
- package/dist/server/unmatched_route.js +64 -0
- package/dist/testing/CLAUDE.md +406 -1202
- package/dist/testing/app_server.d.ts +3 -1
- package/dist/testing/app_server.d.ts.map +1 -1
- package/dist/testing/app_server.js +5 -9
- package/dist/testing/auth_apps.d.ts.map +1 -1
- package/dist/testing/auth_apps.js +3 -2
- package/dist/testing/cross_backend/account_lifecycle.d.ts +11 -4
- package/dist/testing/cross_backend/account_lifecycle.d.ts.map +1 -1
- package/dist/testing/cross_backend/account_lifecycle.js +320 -6
- package/dist/testing/cross_backend/build_test_backend_paths.d.ts +4 -1
- package/dist/testing/cross_backend/build_test_backend_paths.d.ts.map +1 -1
- package/dist/testing/cross_backend/build_test_backend_paths.js +1 -1
- package/dist/testing/cross_backend/capabilities.d.ts +68 -5
- package/dist/testing/cross_backend/capabilities.d.ts.map +1 -1
- package/dist/testing/cross_backend/capabilities.js +20 -4
- package/dist/testing/cross_backend/cell_gated_create.js +1 -1
- package/dist/testing/cross_backend/conformance_case.d.ts +63 -21
- package/dist/testing/cross_backend/conformance_case.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_table.d.ts +54 -12
- package/dist/testing/cross_backend/conformance_table.d.ts.map +1 -1
- package/dist/testing/cross_backend/conformance_table.js +179 -23
- package/dist/testing/cross_backend/cookie_attributes.js +1 -1
- package/dist/testing/cross_backend/create_dual_spawn_global_setup.d.ts +7 -1
- package/dist/testing/cross_backend/create_dual_spawn_global_setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/create_dual_spawn_global_setup.js +3 -3
- package/dist/testing/cross_backend/credential_conformance.d.ts +196 -0
- package/dist/testing/cross_backend/credential_conformance.d.ts.map +1 -0
- package/dist/testing/cross_backend/credential_conformance.js +296 -0
- package/dist/testing/cross_backend/credential_conformance.json +1284 -0
- package/dist/testing/cross_backend/credential_conformance_wire.d.ts +40 -0
- package/dist/testing/cross_backend/credential_conformance_wire.d.ts.map +1 -0
- package/dist/testing/cross_backend/credential_conformance_wire.js +293 -0
- package/dist/testing/cross_backend/credential_header_robustness.d.ts +1 -3
- package/dist/testing/cross_backend/credential_header_robustness.d.ts.map +1 -1
- package/dist/testing/cross_backend/credential_header_robustness.js +24 -55
- package/dist/testing/cross_backend/credential_wire.d.ts +112 -0
- package/dist/testing/cross_backend/credential_wire.d.ts.map +1 -0
- package/dist/testing/cross_backend/credential_wire.js +188 -0
- package/dist/testing/cross_backend/default_backend_configs.d.ts.map +1 -1
- package/dist/testing/cross_backend/default_backend_configs.js +22 -2
- package/dist/testing/cross_backend/default_spine_surface.d.ts +1 -26
- package/dist/testing/cross_backend/default_spine_surface.d.ts.map +1 -1
- package/dist/testing/cross_backend/default_spine_surface.js +3 -7
- package/dist/testing/cross_backend/differential.d.ts +1 -1
- package/dist/testing/cross_backend/differential.d.ts.map +1 -1
- package/dist/testing/cross_backend/differential.js +3 -2
- package/dist/testing/cross_backend/differential_normalize.d.ts +23 -6
- package/dist/testing/cross_backend/differential_normalize.d.ts.map +1 -1
- package/dist/testing/cross_backend/differential_normalize.js +11 -5
- package/dist/testing/cross_backend/full_spine_mount.d.ts +4 -10
- package/dist/testing/cross_backend/full_spine_mount.d.ts.map +1 -1
- package/dist/testing/cross_backend/full_spine_mount.js +11 -4
- package/dist/testing/cross_backend/identity_parity.d.ts.map +1 -1
- package/dist/testing/cross_backend/identity_parity.js +4 -0
- package/dist/testing/cross_backend/in_process_setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/in_process_setup.js +78 -4
- package/dist/testing/cross_backend/login_security.d.ts.map +1 -1
- package/dist/testing/cross_backend/login_security.js +13 -10
- package/dist/testing/cross_backend/peer_ping_ws.d.ts +1 -1
- package/dist/testing/cross_backend/peer_ping_ws.js +2 -2
- package/dist/testing/cross_backend/request_header_conformance.d.ts +174 -0
- package/dist/testing/cross_backend/request_header_conformance.d.ts.map +1 -0
- package/dist/testing/cross_backend/request_header_conformance.js +196 -0
- package/dist/testing/cross_backend/request_header_conformance.json +1158 -0
- package/dist/testing/cross_backend/request_header_conformance_wire.d.ts +39 -0
- package/dist/testing/cross_backend/request_header_conformance_wire.d.ts.map +1 -0
- package/dist/testing/cross_backend/request_header_conformance_wire.js +284 -0
- package/dist/testing/cross_backend/request_target_conformance.d.ts +298 -0
- package/dist/testing/cross_backend/request_target_conformance.d.ts.map +1 -0
- package/dist/testing/cross_backend/request_target_conformance.js +186 -0
- package/dist/testing/cross_backend/request_target_conformance.json +3765 -0
- package/dist/testing/cross_backend/request_target_conformance_wire.d.ts +32 -0
- package/dist/testing/cross_backend/request_target_conformance_wire.d.ts.map +1 -0
- package/dist/testing/cross_backend/request_target_conformance_wire.js +278 -0
- package/dist/testing/cross_backend/role_grant_offer_lifecycle.d.ts.map +1 -1
- package/dist/testing/cross_backend/role_grant_offer_lifecycle.js +173 -1
- package/dist/testing/cross_backend/role_grant_offer_notification_ws.d.ts +5 -4
- package/dist/testing/cross_backend/role_grant_offer_notification_ws.d.ts.map +1 -1
- package/dist/testing/cross_backend/role_grant_offer_notification_ws.js +185 -31
- package/dist/testing/cross_backend/rpc_adversarial.d.ts +6 -4
- package/dist/testing/cross_backend/rpc_adversarial.d.ts.map +1 -1
- package/dist/testing/cross_backend/rpc_adversarial.js +5 -2
- package/dist/testing/cross_backend/rust_spine_consumer_surface.d.ts +6 -7
- package/dist/testing/cross_backend/rust_spine_consumer_surface.d.ts.map +1 -1
- package/dist/testing/cross_backend/rust_spine_consumer_surface.js +4 -5
- package/dist/testing/cross_backend/session_cap.d.ts.map +1 -1
- package/dist/testing/cross_backend/session_cap.js +82 -34
- package/dist/testing/cross_backend/session_cookie_effect.d.ts +43 -0
- package/dist/testing/cross_backend/session_cookie_effect.d.ts.map +1 -0
- package/dist/testing/cross_backend/session_cookie_effect.js +103 -0
- package/dist/testing/cross_backend/session_login.d.ts +24 -0
- package/dist/testing/cross_backend/session_login.d.ts.map +1 -0
- package/dist/testing/cross_backend/session_login.js +31 -0
- package/dist/testing/cross_backend/setup.d.ts +117 -0
- package/dist/testing/cross_backend/setup.d.ts.map +1 -1
- package/dist/testing/cross_backend/setup.js +193 -9
- package/dist/testing/cross_backend/simple_request.d.ts.map +1 -1
- package/dist/testing/cross_backend/simple_request.js +5 -0
- package/dist/testing/cross_backend/spine_suites.d.ts +9 -1
- package/dist/testing/cross_backend/spine_suites.d.ts.map +1 -1
- package/dist/testing/cross_backend/spine_suites.js +88 -5
- package/dist/testing/cross_backend/spine_surface_constants.d.ts +1 -1
- package/dist/testing/cross_backend/spine_surface_constants.d.ts.map +1 -1
- package/dist/testing/cross_backend/spine_surface_constants.js +1 -0
- package/dist/testing/cross_backend/sse_round_trip.d.ts +8 -5
- package/dist/testing/cross_backend/sse_round_trip.d.ts.map +1 -1
- package/dist/testing/cross_backend/sse_round_trip.js +205 -64
- package/dist/testing/cross_backend/testing_backdoor.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_backdoor.js +5 -2
- package/dist/testing/cross_backend/testing_credential_read.d.ts +165 -0
- package/dist/testing/cross_backend/testing_credential_read.d.ts.map +1 -0
- package/dist/testing/cross_backend/testing_credential_read.js +175 -0
- package/dist/testing/cross_backend/testing_reset_actions.d.ts +19 -0
- package/dist/testing/cross_backend/testing_reset_actions.d.ts.map +1 -1
- package/dist/testing/cross_backend/testing_reset_actions.js +22 -6
- package/dist/testing/cross_backend/token_lifetime.d.ts.map +1 -1
- package/dist/testing/cross_backend/token_lifetime.js +58 -2
- package/dist/testing/cross_backend/transport_composition.d.ts +2 -4
- package/dist/testing/cross_backend/transport_composition.d.ts.map +1 -1
- package/dist/testing/cross_backend/transport_composition.js +13 -10
- package/dist/testing/cross_backend/ts_spine_backend_config.d.ts.map +1 -1
- package/dist/testing/cross_backend/ts_spine_backend_config.js +5 -3
- package/dist/testing/cross_backend/ws_endpoint.d.ts +11 -1
- package/dist/testing/cross_backend/ws_endpoint.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_endpoint.js +19 -2
- package/dist/testing/cross_backend/ws_role_gated.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_role_gated.js +2 -3
- package/dist/testing/cross_backend/ws_round_trip.d.ts.map +1 -1
- package/dist/testing/cross_backend/ws_round_trip.js +28 -12
- package/dist/testing/cross_backend/xfail.d.ts +44 -11
- package/dist/testing/cross_backend/xfail.d.ts.map +1 -1
- package/dist/testing/cross_backend/xfail.js +68 -23
- package/dist/testing/data_exposure.d.ts.map +1 -1
- package/dist/testing/data_exposure.js +4 -3
- package/dist/testing/integration.d.ts +1 -2
- package/dist/testing/integration.d.ts.map +1 -1
- package/dist/testing/integration.js +14 -8
- package/dist/testing/integration_helpers.d.ts +50 -3
- package/dist/testing/integration_helpers.d.ts.map +1 -1
- package/dist/testing/integration_helpers.js +87 -9
- package/dist/testing/middleware.d.ts +3 -1
- package/dist/testing/middleware.d.ts.map +1 -1
- package/dist/testing/middleware.js +14 -7
- package/dist/testing/resolved_auth.d.ts +3 -1
- package/dist/testing/resolved_auth.d.ts.map +1 -1
- package/dist/testing/resolved_auth.js +4 -4
- package/dist/testing/round_trip.d.ts +6 -2
- package/dist/testing/round_trip.d.ts.map +1 -1
- package/dist/testing/round_trip.js +17 -6
- package/dist/testing/rpc_envelope_cases.d.ts.map +1 -1
- package/dist/testing/rpc_envelope_cases.js +7 -0
- package/dist/testing/rpc_helpers.d.ts +4 -2
- package/dist/testing/rpc_helpers.d.ts.map +1 -1
- package/dist/testing/rpc_helpers.js +6 -1
- package/dist/testing/rpc_round_trip.d.ts +13 -2
- package/dist/testing/rpc_round_trip.d.ts.map +1 -1
- package/dist/testing/rpc_round_trip.js +25 -6
- package/dist/testing/schema_generators.d.ts +2 -2
- package/dist/testing/schema_generators.d.ts.map +1 -1
- package/dist/testing/schema_generators.js +4 -4
- package/dist/testing/stubs.d.ts +2 -2
- package/dist/testing/stubs.d.ts.map +1 -1
- package/dist/testing/stubs.js +13 -10
- package/dist/testing/transports/fetch_transport.d.ts +6 -3
- package/dist/testing/transports/fetch_transport.d.ts.map +1 -1
- package/dist/testing/transports/fetch_transport.js +31 -19
- package/dist/testing/transports/raw_http.d.ts +61 -1
- package/dist/testing/transports/raw_http.d.ts.map +1 -1
- package/dist/testing/transports/raw_http.js +61 -1
- package/dist/testing/transports/ws_raw_client.d.ts +20 -0
- package/dist/testing/transports/ws_raw_client.d.ts.map +1 -1
- package/dist/testing/transports/ws_raw_client.js +10 -4
- package/dist/testing/transports/ws_transport.d.ts +21 -1
- package/dist/testing/transports/ws_transport.d.ts.map +1 -1
- package/dist/testing/transports/ws_transport.js +58 -20
- package/dist/testing/ws_round_trip.d.ts.map +1 -1
- package/dist/testing/ws_round_trip.js +8 -4
- package/package.json +1 -1
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import '../assert_dev_env.js';
|
|
2
2
|
import type { TestingBackdoorMethod } from './spine_surface_constants.js';
|
|
3
|
+
/**
|
|
4
|
+
* The upgrade refusals a runtime makes before the app runs, which
|
|
5
|
+
* `BackendCapabilities.ws_upgrade_runtime_refusals` declares: `empty_host`, an
|
|
6
|
+
* upgrade whose first `Host` line is empty.
|
|
7
|
+
*/
|
|
8
|
+
export declare const WS_UPGRADE_RUNTIME_REFUSALS: readonly ["empty_host"];
|
|
9
|
+
/** One of `WS_UPGRADE_RUNTIME_REFUSALS`. */
|
|
10
|
+
export type WsUpgradeRuntimeRefusal = (typeof WS_UPGRADE_RUNTIME_REFUSALS)[number];
|
|
3
11
|
/**
|
|
4
12
|
* Optional behaviors a backend may support. Each flag's TSDoc names the
|
|
5
13
|
* tests that gate on it; add a new flag here before referencing it from
|
|
@@ -207,16 +215,70 @@ export interface BackendCapabilities {
|
|
|
207
215
|
/**
|
|
208
216
|
* A refused WebSocket upgrade carries its refusal body — the flat
|
|
209
217
|
* `{error, ...}` the same refusal answers over plain HTTP. Not a gate: it
|
|
210
|
-
* forks how `describe_transport_composition_cross_tests` reads its WS rows
|
|
211
|
-
*
|
|
212
|
-
*
|
|
213
|
-
*
|
|
218
|
+
* forks how `describe_transport_composition_cross_tests` reads its WS rows
|
|
219
|
+
* and how `describe_cross_process_ws_tests` reads its disallowed-origin
|
|
220
|
+
* refusal. `true`, an empty refusal body fails the case; `false`, an empty
|
|
221
|
+
* body is allowed (the case pins the status alone) and a non-empty one is
|
|
222
|
+
* still asserted.
|
|
214
223
|
*
|
|
215
224
|
* `false` on Node: `@hono/node-server` writes a refused upgrade to the raw
|
|
216
225
|
* socket with `Content-Length: 0`, dropping the response body. `true` on
|
|
217
226
|
* Bun and the Rust spine, which send the response as built.
|
|
218
227
|
*/
|
|
219
228
|
readonly ws_refusal_body: boolean;
|
|
229
|
+
/**
|
|
230
|
+
* The upgrade requests the runtime refuses itself, before the app runs —
|
|
231
|
+
* each a `WsUpgradeRuntimeRefusal`. Not a gate: the request header wire
|
|
232
|
+
* leg (`describe_request_header_conformance_wire_cross_tests`) expects that
|
|
233
|
+
* runtime answer, a `400` and no `101`, for a row naming a refusal the
|
|
234
|
+
* backend declares, and the table's own answer on every other backend — so
|
|
235
|
+
* the declaration fails the day the runtime stops refusing.
|
|
236
|
+
*
|
|
237
|
+
* `['empty_host']` on Node: `@hono/node-server` builds an upgrade's URL from
|
|
238
|
+
* the first `Host` line, and an empty one makes that throw, which it
|
|
239
|
+
* answers with a bodiless `400`. `[]` on Bun and the Rust spine, whose host
|
|
240
|
+
* gate answers the request.
|
|
241
|
+
*/
|
|
242
|
+
readonly ws_upgrade_runtime_refusals: ReadonlyArray<WsUpgradeRuntimeRefusal>;
|
|
243
|
+
/**
|
|
244
|
+
* The backend's runtime resolves dot segments — `.` and `..`, literal or
|
|
245
|
+
* percent-encoded (`%2e`) — before the app sees the request, so the router
|
|
246
|
+
* reads `/api/../health` as `/health`. Not a gate: the request target wire
|
|
247
|
+
* leg (`describe_request_target_conformance_wire_cross_tests`) expects a
|
|
248
|
+
* dot-segment row's `expect_where_dot_segments_resolved` answer where it is
|
|
249
|
+
* `true` and the row's raw-path `expect` where it is `false`, so the
|
|
250
|
+
* declaration fails the day the runtime changes.
|
|
251
|
+
*
|
|
252
|
+
* `true` on Node and Bun, which build the request's URL by the WHATWG URL
|
|
253
|
+
* parser (Bun keeps no raw target at all), and in-process, where the
|
|
254
|
+
* `Request` does the same; `false` on the Rust spine, whose router matches
|
|
255
|
+
* the raw path, dot segments kept.
|
|
256
|
+
*/
|
|
257
|
+
readonly runtime_resolves_dot_segments: boolean;
|
|
258
|
+
/**
|
|
259
|
+
* An unmatched path outside the auth scope is answered by the spine's own
|
|
260
|
+
* fallback — the plain-text `404 Not Found`. Gates the request target wire leg's
|
|
261
|
+
* rows that land outside `/api` (`requires`), so a backend serving a
|
|
262
|
+
* static or SPA fallback of its own there declares `false` and keeps the
|
|
263
|
+
* rest of the leg; those rows then show as a skipped test.
|
|
264
|
+
*
|
|
265
|
+
* `true` in both families' defaults, on fuz_app's spine presets and
|
|
266
|
+
* in-process.
|
|
267
|
+
*/
|
|
268
|
+
readonly spine_fallback: boolean;
|
|
269
|
+
/**
|
|
270
|
+
* The host gate (DNS rebinding) is on, refusing a `Host` that is neither
|
|
271
|
+
* loopback nor allowlisted with 403 `forbidden_host`. Gates the request
|
|
272
|
+
* header wire leg's rows the table expects the host gate to refuse
|
|
273
|
+
* (`describe_request_header_conformance_wire_cross_tests`), so a backend
|
|
274
|
+
* running with the gate off (`host_gate: false` on `create_app_server`)
|
|
275
|
+
* declares `false` and keeps the rest of the leg; those rows then show as a
|
|
276
|
+
* skipped test.
|
|
277
|
+
*
|
|
278
|
+
* `true` in both families' defaults, on fuz_app's spine presets and
|
|
279
|
+
* in-process — the gate is on by default on both spines.
|
|
280
|
+
*/
|
|
281
|
+
readonly host_gate: boolean;
|
|
220
282
|
/**
|
|
221
283
|
* The `_testing_*` backdoors the backend mounts on its RPC endpoint, from
|
|
222
284
|
* `TESTING_BACKDOOR_METHODS` (a consumer's own seams stay off it). Not a
|
|
@@ -226,7 +288,8 @@ export interface BackendCapabilities {
|
|
|
226
288
|
* must answer `method_not_found` — and runs its credential-gate rows over
|
|
227
289
|
* the declared ones; `describe_spine_cross_suites` requires `_testing_reset`
|
|
228
290
|
* and `_testing_drain_effects` (the per-test reset and the audit barrier),
|
|
229
|
-
* skips a suite whose backdoor is undeclared, naming it — `
|
|
291
|
+
* skips a suite whose backdoor is undeclared, naming it — `credential_conformance`
|
|
292
|
+
* (`_testing_credential_read`), `credential_deadline`
|
|
230
293
|
* (`_testing_shorten_credential_expiry`), `origin_conformance`
|
|
231
294
|
* (`_testing_origin_check`), `ws_outbound_overflow`
|
|
232
295
|
* (`_testing_flood_notifications`) — and requires `_testing_put_fact` of a
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capabilities.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"capabilities.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAmD9B,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAE1E;;;;GAIG;AACH,eAAO,MAAM,2BAA2B,yBAA0B,CAAC;AAEnE,4CAA4C;AAC5C,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,2BAA2B,CAAC,CAAC,MAAM,CAAC,CAAC;AAEnF;;;;;GAKG;AACH,MAAM,WAAW,mBAAmB;IACnC;;;;;;;;OAQG;IACH,QAAQ,CAAC,EAAE,EAAE,OAAO,CAAC;IACrB;;;;;OAKG;IACH,QAAQ,CAAC,GAAG,EAAE,OAAO,CAAC;IACtB;;;;;;;OAOG;IACH,QAAQ,CAAC,SAAS,EAA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;OAmBG;IACH,QAAQ,CAAC,iBAAiB,EAAE,aAAa,CAAC,qBAAqB,CAAC,CAAC;CACjE;AAED;;;;;;;;GAQG;AACH,MAAM,MAAM,SAAS,GAAG,MAAM,IAAI,CACjC,mBAAmB,EACjB,IAAI,GACJ,KAAK,GACL,WAAW,GACX,gBAAgB,GAChB,mBAAmB,GACnB,cAAc,GACd,yBAAyB,GACzB,OAAO,GACP,cAAc,GACd,oBAAoB,GACpB,eAAe,GACf,OAAO,CACT,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,MAAM,MAAM,yBAAyB,GAAG,IAAI,CAAC,mBAAmB,EAAE,SAAS,GAAG,mBAAmB,CAAC,CAAC;AAEnG;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,uBAAuB,EAAE,mBAwCpC,CAAC;AAEH;;;;;;;;GAQG;AACH,eAAO,MAAM,OAAO,GAAI,MAAM,OAAO,EAAE,MAAM,MAAM,EAAE,IAAI,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAG,IAMrF,CAAC"}
|
|
@@ -31,8 +31,9 @@ import '../assert_dev_env.js';
|
|
|
31
31
|
* (a `MountFlag`) is never inherited, nor is the `testing_backdoors` list: the
|
|
32
32
|
* family defaults are `FamilyDefaultCapabilities`, which omits them, so every
|
|
33
33
|
* backend config states each one. The family defaults carry only what the family guarantees — the
|
|
34
|
-
* declared spine surface's mounts (`account_lifecycle`,
|
|
35
|
-
* the runtime behavior of its
|
|
34
|
+
* declared spine surface's mounts, fallback and host gate (`account_lifecycle`,
|
|
35
|
+
* `account_status`, `spine_fallback`, `host_gate`) and the runtime behavior of its
|
|
36
|
+
* reference runtime (`ws_handshake_pipelining`,
|
|
36
37
|
* `ws_refusal_body`: Node for TS, hyper for Rust), which a backend on another
|
|
37
38
|
* runtime overrides.
|
|
38
39
|
*
|
|
@@ -45,6 +46,12 @@ import '../assert_dev_env.js';
|
|
|
45
46
|
* @module
|
|
46
47
|
*/
|
|
47
48
|
import { test } from 'vitest';
|
|
49
|
+
/**
|
|
50
|
+
* The upgrade refusals a runtime makes before the app runs, which
|
|
51
|
+
* `BackendCapabilities.ws_upgrade_runtime_refusals` declares: `empty_host`, an
|
|
52
|
+
* upgrade whose first `Host` line is empty.
|
|
53
|
+
*/
|
|
54
|
+
export const WS_UPGRADE_RUNTIME_REFUSALS = ['empty_host'];
|
|
48
55
|
/**
|
|
49
56
|
* Capability declarations for the in-process Hono transport. Nearly every
|
|
50
57
|
* flag is `true` because in-process testing exercises the full backend
|
|
@@ -83,9 +90,18 @@ export const in_process_capabilities = Object.freeze({
|
|
|
83
90
|
// Cross-process-only: the room verbs are a spine-binary WS mount, and the
|
|
84
91
|
// suite reads real sockets' pushes.
|
|
85
92
|
rooms: false,
|
|
86
|
-
// Read only by the front-door table's WS rows
|
|
87
|
-
//
|
|
93
|
+
// Read only by the front-door table's WS rows and the WS suite's
|
|
94
|
+
// disallowed-origin case, neither of which runs in-process (no socket to
|
|
95
|
+
// upgrade); Hono's own refusals carry their bodies.
|
|
88
96
|
ws_refusal_body: true,
|
|
97
|
+
// Read only by the request header wire leg, which has no socket in-process.
|
|
98
|
+
ws_upgrade_runtime_refusals: Object.freeze([]),
|
|
99
|
+
// A `Request` built from a URL resolves dot segments, as both TS runtimes do.
|
|
100
|
+
runtime_resolves_dot_segments: true,
|
|
101
|
+
// The test app serves no fallback of its own.
|
|
102
|
+
spine_fallback: true,
|
|
103
|
+
// `create_app_server` mounts the host gate by default.
|
|
104
|
+
host_gate: true,
|
|
89
105
|
// The in-process app mounts no `_testing_*` action; the suites reading this
|
|
90
106
|
// are cross-process only.
|
|
91
107
|
testing_backdoors: Object.freeze([])
|
|
@@ -11,7 +11,7 @@ import '../assert_dev_env.js';
|
|
|
11
11
|
* spines.
|
|
12
12
|
*
|
|
13
13
|
* Both spines mount the same directory-model policy (the TS spine binary via
|
|
14
|
-
* `
|
|
14
|
+
* `test_cell_gated_create_authorize`, the Rust `testing_spine_stub` via
|
|
15
15
|
* `TestCellGatedCreateAuthorize`): admin bypasses; a non-admin creating a
|
|
16
16
|
* `kind: 'space'` **root** is denied (admin-only); a **contribution** under a
|
|
17
17
|
* space is gated by the space's `policy[kind] = {min_role, moderation_required}`
|
|
@@ -23,6 +23,9 @@ import '../assert_dev_env.js';
|
|
|
23
23
|
*
|
|
24
24
|
* @module
|
|
25
25
|
*/
|
|
26
|
+
import type { JsonrpcErrorCode } from '../../http/jsonrpc.js';
|
|
27
|
+
import type { XfailMarker } from './xfail.js';
|
|
28
|
+
import type { SessionCookieEffect } from './session_cookie_effect.js';
|
|
26
29
|
/**
|
|
27
30
|
* Closed enum of fixture-provisioned principals a case runs `as`. Each
|
|
28
31
|
* value maps to a `TestFixture` accessor (or a seeded `extra_accounts`
|
|
@@ -92,8 +95,29 @@ import '../assert_dev_env.js';
|
|
|
92
95
|
* server-side session* cookie (minted by `fixture.mint_expired_session()`:
|
|
93
96
|
* a backdated `auth_session` row behind a still-valid signed cookie
|
|
94
97
|
* payload, so the authoritative DB-row expiry gate is what refuses it).
|
|
98
|
+
*
|
|
99
|
+
* The dead credentials — each presented alone, on a fresh jar, so the request
|
|
100
|
+
* carries that credential and nothing else; each arrives anonymous, so a row
|
|
101
|
+
* pins the refusal anonymous gets on its target, byte for byte:
|
|
102
|
+
*
|
|
103
|
+
* - `tampered_cookie` — the keeper's session cookie with its MAC corrupted
|
|
104
|
+
* (the first character of the signature changed, the signature still
|
|
105
|
+
* well-shaped): present and invalid, so besides refusing it the response
|
|
106
|
+
* clears the cookie (`expect.set_cookie: 'clear'`).
|
|
107
|
+
* - `wrong_daemon` — a well-shaped daemon token (43 base64url characters) that
|
|
108
|
+
* is not the server's, with no `Origin`, so it reaches the token compare
|
|
109
|
+
* rather than the browser-context discard.
|
|
110
|
+
* - `unknown_bearer` — a well-shaped API token (`secret_fuz_token_` + 43
|
|
111
|
+
* base64url characters) no row matches, with no `Origin`.
|
|
112
|
+
* - `revoked_session` — a session cookie that verifies, whose `auth_session`
|
|
113
|
+
* row has been revoked (`fixture.mint_revoked_session()`). The cookie alone
|
|
114
|
+
* shows nothing wrong, so it is not cleared.
|
|
115
|
+
* - `revoked_token` — an API token that was minted and then revoked
|
|
116
|
+
* (`fixture.mint_revoked_token()`), with no `Origin`.
|
|
117
|
+
* - `expired_token` — an API token whose row is past its `expires_at`
|
|
118
|
+
* (`fixture.mint_expired_token()`), with no `Origin`.
|
|
95
119
|
*/
|
|
96
|
-
export type ConformancePrincipal = 'keeper' | 'daemon' | 'invalid_daemon' | 'daemon_browser' | 'token' | 'bearer_browser' | 'malformed_bearer' | 'scoped_token' | 'anonymous' | 'fresh_non_admin' | 'role_holder' | 'wrong_role' | 'expired_session';
|
|
120
|
+
export type ConformancePrincipal = 'keeper' | 'daemon' | 'invalid_daemon' | 'daemon_browser' | 'token' | 'bearer_browser' | 'malformed_bearer' | 'scoped_token' | 'anonymous' | 'fresh_non_admin' | 'role_holder' | 'wrong_role' | 'expired_session' | 'tampered_cookie' | 'wrong_daemon' | 'unknown_bearer' | 'revoked_session' | 'revoked_token' | 'expired_token';
|
|
97
121
|
/**
|
|
98
122
|
* The single RPC method the `scoped_token` principal's narrowed token admits.
|
|
99
123
|
*
|
|
@@ -126,7 +150,8 @@ export declare const SCOPED_TOKEN_ADMITTED_METHOD = "account_verify";
|
|
|
126
150
|
* a principal on another account names a real actor that is not its own.
|
|
127
151
|
*
|
|
128
152
|
* Unavailable for principals that present no account (`anonymous`,
|
|
129
|
-
* `bearer_browser`, `malformed_bearer
|
|
153
|
+
* `bearer_browser`, `malformed_bearer`, and the dead credentials
|
|
154
|
+
* `tampered_cookie` … `expired_token`) — the runner throws.
|
|
130
155
|
*/
|
|
131
156
|
export type ConformanceActingBinding = 'principal' | 'extra_actor' | 'keeper_actor';
|
|
132
157
|
/** The request a conformance case issues. */
|
|
@@ -159,15 +184,37 @@ export interface ConformanceCaseRequest {
|
|
|
159
184
|
export interface ConformanceCaseExpectation {
|
|
160
185
|
/** Expected HTTP status code. */
|
|
161
186
|
status: number;
|
|
187
|
+
/**
|
|
188
|
+
* The JSON-RPC `error.code` an RPC error row must carry, on the HTTP and WS
|
|
189
|
+
* legs alike. Omitted, it is the code the spine maps `status` back to
|
|
190
|
+
* (`http_status_to_jsonrpc_error_code` — `invalid_params` for `400`,
|
|
191
|
+
* `not_found` for `404`, `rate_limited` for `429`). That mapping is
|
|
192
|
+
* many-to-one, so a refusal under another code sharing its status
|
|
193
|
+
* (`invalid_request` or `parse_error` at `400`, `method_not_found` at
|
|
194
|
+
* `404`, a consumer code `register_jsonrpc_error_code` declared) names its
|
|
195
|
+
* code here. RPC rows only: a REST row setting it is refused at collection.
|
|
196
|
+
*/
|
|
197
|
+
error_code?: JsonrpcErrorCode;
|
|
162
198
|
/**
|
|
163
199
|
* Expected error reason — pass the IMPORTED `ERROR_*` constant from
|
|
164
200
|
* `http/error_schemas.ts`, never a string literal. Asserted against the RPC
|
|
165
|
-
* `error.data.reason`
|
|
166
|
-
*
|
|
167
|
-
*
|
|
168
|
-
*
|
|
201
|
+
* `error.data.reason` or the REST flat-body `error` field. `null` pins the
|
|
202
|
+
* reason absent: an RPC error carrying no `data.reason` (a handler's bare
|
|
203
|
+
* `forbidden`). A REST error body always names its code in `error`, so a REST
|
|
204
|
+
* row pins that code instead; `null` there is refused at collection.
|
|
205
|
+
* Omitted, the reason is not asserted.
|
|
206
|
+
*/
|
|
207
|
+
error_reason?: string | null;
|
|
208
|
+
/**
|
|
209
|
+
* What the response does to the session cookie (`SessionCookieEffect`), read
|
|
210
|
+
* off its `Set-Cookie` lines for the session cookie's name. Omitted means
|
|
211
|
+
* `'none'` — no line for it — so every row that does not name an effect pins
|
|
212
|
+
* that it sets and clears nothing. HTTP legs only: a row naming `'clear'`,
|
|
213
|
+
* `'set'` or `'clear_then_set'` is no WS case (`is_ws_conformance_case`).
|
|
214
|
+
* A row whose status is not 2xx can't name `'set'` or `'clear_then_set'`:
|
|
215
|
+
* the collection refuses it, since no refusal may mint a session cookie.
|
|
169
216
|
*/
|
|
170
|
-
|
|
217
|
+
set_cookie?: SessionCookieEffect;
|
|
171
218
|
/**
|
|
172
219
|
* Specific field-value assertions on the success `result` (2xx) or the
|
|
173
220
|
* error `error.data` (non-2xx). Each key must deep-equal the corresponding
|
|
@@ -209,19 +256,6 @@ export interface ConformanceCaseExpectation {
|
|
|
209
256
|
*/
|
|
210
257
|
equivalence_group?: string;
|
|
211
258
|
}
|
|
212
|
-
/**
|
|
213
|
-
* Marks a case as a deferred-by-design gap. The runner routes it through
|
|
214
|
-
* `xfail_until` instead of a normal `test` — visible (distinct from pass)
|
|
215
|
-
* and self-cleaning (flips red when the impl starts passing, forcing the
|
|
216
|
-
* marker's removal). Use for declared gaps (e.g. facts), never for
|
|
217
|
-
* in-scope gaps (those fail loud as a red `test`).
|
|
218
|
-
*/
|
|
219
|
-
export interface ConformanceCaseXfail {
|
|
220
|
-
/** Tracking id for the deferred gap (issue id or tracking slug). */
|
|
221
|
-
tracking_id: string;
|
|
222
|
-
/** Why this case is deferred-by-design. */
|
|
223
|
-
reason: string;
|
|
224
|
-
}
|
|
225
259
|
/**
|
|
226
260
|
* A single conformance case. `name` is the assertion; the optional
|
|
227
261
|
* free-text `note` is printed in the test label / failure output. A
|
|
@@ -239,6 +273,14 @@ export interface ConformanceCase {
|
|
|
239
273
|
expect: ConformanceCaseExpectation;
|
|
240
274
|
/** Free-text note printed in the label / failure output. */
|
|
241
275
|
note?: string;
|
|
242
|
-
|
|
276
|
+
/**
|
|
277
|
+
* Marks the case a deferred-by-design gap. The runner routes it through
|
|
278
|
+
* `xfail_until` instead of a normal `test` — visible (distinct from pass),
|
|
279
|
+
* specific (red on any failure but the one `fails_with` names), and
|
|
280
|
+
* self-cleaning (flips red when the impl starts passing, forcing the
|
|
281
|
+
* marker's removal). Use for declared gaps (e.g. facts), never for
|
|
282
|
+
* in-scope gaps (those fail loud as a red `test`).
|
|
283
|
+
*/
|
|
284
|
+
xfail?: XfailMarker;
|
|
243
285
|
}
|
|
244
286
|
//# sourceMappingURL=conformance_case.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conformance_case.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/conformance_case.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH
|
|
1
|
+
{"version":3,"file":"conformance_case.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/conformance_case.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEtE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0FG;AACH,MAAM,MAAM,oBAAoB,GAC7B,QAAQ,GACR,QAAQ,GACR,gBAAgB,GAChB,gBAAgB,GAChB,OAAO,GACP,gBAAgB,GAChB,kBAAkB,GAClB,cAAc,GACd,WAAW,GACX,iBAAiB,GACjB,aAAa,GACb,YAAY,GACZ,iBAAiB,GACjB,iBAAiB,GACjB,cAAc,GACd,gBAAgB,GAChB,iBAAiB,GACjB,eAAe,GACf,eAAe,CAAC;AAEnB;;;;;;;;;GASG;AACH,eAAO,MAAM,4BAA4B,mBAAmB,CAAC;AAE7D;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,MAAM,wBAAwB,GAAG,WAAW,GAAG,aAAa,GAAG,cAAc,CAAC;AAEpF,6CAA6C;AAC7C,MAAM,WAAW,sBAAsB;IACtC;;;;OAIG;IACH,MAAM,EAAE,MAAM,CAAC;IACf,uDAAuD;IACvD,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,EAAE,EAAE,oBAAoB,CAAC;IACzB;;;;OAIG;IACH,MAAM,CAAC,EAAE,wBAAwB,CAAC;IAClC,4EAA4E;IAC5E,IAAI,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;CACtB;AAED,8DAA8D;AAC9D,MAAM,WAAW,0BAA0B;IAC1C,iCAAiC;IACjC,MAAM,EAAE,MAAM,CAAC;IACf;;;;;;;;;OASG;IACH,UAAU,CAAC,EAAE,gBAAgB,CAAC;IAC9B;;;;;;;;OAQG;IACH,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC7B;;;;;;;;OAQG;IACH,UAAU,CAAC,EAAE,mBAAmB,CAAC;IACjC;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACjC;;;;;;;;;;OAUG;IACH,aAAa,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAC9B;;;;;;;;OAQG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC,CAAC;IACxC;;;;;;;;;;OAUG;IACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED;;;;;;;;;GASG;AACH,MAAM,WAAW,eAAe;IAC/B,6CAA6C;IAC7C,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,sBAAsB,CAAC;IAChC,MAAM,EAAE,0BAA0B,CAAC;IACnC,4DAA4D;IAC5D,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;;;;;OAOG;IACH,KAAK,CAAC,EAAE,WAAW,CAAC;CACpB"}
|
|
@@ -77,8 +77,9 @@ export declare const resolve_conformance_rpc_endpoints: (options: ConformanceRpc
|
|
|
77
77
|
/**
|
|
78
78
|
* Whether a case can run over a WebSocket: an RPC method (not a REST auth
|
|
79
79
|
* route), sent as `POST` (a `GET` row pins the HTTP query path), pinning no
|
|
80
|
-
* header value (a frame has no headers; an
|
|
81
|
-
* a principal that can
|
|
80
|
+
* header value and no session cookie effect (a frame has no headers; an
|
|
81
|
+
* absence pin, `'none'` included, holds vacuously), as a principal that can
|
|
82
|
+
* hold a socket.
|
|
82
83
|
*
|
|
83
84
|
* @param c - the case
|
|
84
85
|
* @returns whether the WS leg runs it
|
|
@@ -104,9 +105,11 @@ export interface ResolvedConformancePrincipal {
|
|
|
104
105
|
* Map a `ConformancePrincipal` onto the transport + headers it
|
|
105
106
|
* authenticates with, reading exclusively from the per-test `TestFixture`.
|
|
106
107
|
*
|
|
107
|
-
* The
|
|
108
|
-
*
|
|
109
|
-
*
|
|
108
|
+
* The always-available principals resolve from fixture accessors (the dead
|
|
109
|
+
* credentials that need a server-side state — a revoked session or token, an
|
|
110
|
+
* expired token — from the fixture's `mint_*` seams); `role_holder` /
|
|
111
|
+
* `wrong_role` read a seeded `extra_accounts` entry named via
|
|
112
|
+
* `options.principals` (throws a clear setup error when unconfigured);
|
|
110
113
|
* `scoped_token` mints its narrowed credential over the production path.
|
|
111
114
|
* Also used outside the table by suites that send a principal's requests
|
|
112
115
|
* themselves (`describe_rpc_adversarial_cross_tests`).
|
|
@@ -139,6 +142,25 @@ export declare const assert_no_fingerprint_headers: (headers: Record<string, str
|
|
|
139
142
|
* always-on no-fingerprint floor.
|
|
140
143
|
*/
|
|
141
144
|
export declare const assert_expected_headers: (headers: Record<string, string>, expected: Record<string, string | null>, label: string) => void;
|
|
145
|
+
/**
|
|
146
|
+
* Assert a response's session cookie lines against the row's
|
|
147
|
+
* `expect.set_cookie` (omitted, `'none'`), by the classification both the
|
|
148
|
+
* runner and the differential read (`classify_session_cookie_effect`) — the
|
|
149
|
+
* assertion that decides a row.
|
|
150
|
+
*
|
|
151
|
+
* Ahead of it runs the floor: a response that is not 2xx mints no session
|
|
152
|
+
* cookie (`find_session_cookie_mints`, which reads a mint in any shape). It is
|
|
153
|
+
* a backstop, not a second guarantee: `check_conformance_cases` refuses a
|
|
154
|
+
* non-2xx row expecting a mint, so on a row the table collected, a refusal
|
|
155
|
+
* that mints already fails the effect assertion. The floor names the cause
|
|
156
|
+
* plainly when it does, and holds for a caller asserting a row the collection
|
|
157
|
+
* never saw.
|
|
158
|
+
*
|
|
159
|
+
* @param sent - the response, with every `Set-Cookie` line
|
|
160
|
+
* @param c - the case
|
|
161
|
+
* @param cookie_name - the session cookie's name
|
|
162
|
+
*/
|
|
163
|
+
export declare const assert_session_cookie: (sent: Pick<ConformanceCaseResponse, "status" | "set_cookies">, c: ConformanceCase, cookie_name: string) => void;
|
|
142
164
|
/** What `send_conformance_case` needs besides the case. */
|
|
143
165
|
export interface SendConformanceCaseOptions {
|
|
144
166
|
/** The per-test fixture the principal resolves from. */
|
|
@@ -171,20 +193,22 @@ export type ConformanceCaseTarget = {
|
|
|
171
193
|
};
|
|
172
194
|
/**
|
|
173
195
|
* One case's request as sent and its response unparsed: the HTTP status, the
|
|
174
|
-
* response-headers snapshot (lowercased keys),
|
|
175
|
-
* the
|
|
176
|
-
*
|
|
196
|
+
* response-headers snapshot (lowercased keys), every `Set-Cookie` line in
|
|
197
|
+
* order (the snapshot keeps only one), and the JSON body exactly as the server
|
|
198
|
+
* sent it — the whole JSON-RPC envelope for an RPC method, `undefined` for a
|
|
199
|
+
* REST body that is not JSON.
|
|
177
200
|
*
|
|
178
|
-
* Over a WebSocket the body is the response frame, the headers
|
|
179
|
-
* frame carries none), and the status is the
|
|
180
|
-
* for the frame's outcome: `200` for a result,
|
|
181
|
-
* `jsonrpc_error_code_to_http_status` of its error code — so a row's
|
|
201
|
+
* Over a WebSocket the body is the response frame, the headers and
|
|
202
|
+
* `Set-Cookie` lines are empty (a frame carries none), and the status is the
|
|
203
|
+
* one the HTTP binding answers for the frame's outcome: `200` for a result,
|
|
204
|
+
* else `jsonrpc_error_code_to_http_status` of its error code — so a row's
|
|
182
205
|
* `expect.status` reads as the error code on both transports.
|
|
183
206
|
*/
|
|
184
207
|
export interface ConformanceCaseResponse {
|
|
185
208
|
readonly target: ConformanceCaseTarget;
|
|
186
209
|
readonly status: number;
|
|
187
210
|
readonly headers: Record<string, string>;
|
|
211
|
+
readonly set_cookies: ReadonlyArray<string>;
|
|
188
212
|
readonly body: unknown;
|
|
189
213
|
}
|
|
190
214
|
/**
|
|
@@ -202,6 +226,24 @@ export interface ConformanceCaseResponse {
|
|
|
202
226
|
* auth routes
|
|
203
227
|
*/
|
|
204
228
|
export declare const send_conformance_case: (c: ConformanceCase, options: SendConformanceCaseOptions) => Promise<ConformanceCaseResponse>;
|
|
229
|
+
/**
|
|
230
|
+
* Refuse the rows a table can't honestly run, before any is sent, each throw
|
|
231
|
+
* naming the case:
|
|
232
|
+
*
|
|
233
|
+
* - a REST row pinning `error_reason: null` — a REST error body always names
|
|
234
|
+
* its code in `error`, so the row pins that code instead;
|
|
235
|
+
* - a REST row setting `error_code`, which only a JSON-RPC envelope carries;
|
|
236
|
+
* - a row whose status is not 2xx expecting the session cookie minted
|
|
237
|
+
* (`set_cookie` `'set'` or `'clear_then_set'`) — no refusal may mint one,
|
|
238
|
+
* so the row contradicts the floor `assert_session_cookie` holds every
|
|
239
|
+
* response to.
|
|
240
|
+
*
|
|
241
|
+
* `describe_conformance_table_tests` runs it at collection.
|
|
242
|
+
*
|
|
243
|
+
* @param cases - the cases a table would run
|
|
244
|
+
* @throws Error naming the first case that can't be written
|
|
245
|
+
*/
|
|
246
|
+
export declare const check_conformance_cases: (cases: ReadonlyArray<ConformanceCase>) => void;
|
|
205
247
|
/**
|
|
206
248
|
* Register a `describe` block running every `ConformanceCase` as a
|
|
207
249
|
* vitest `test` (or `xfail_until` for deferred-by-design rows). Drives
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"conformance_table.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/conformance_table.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAs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