Orchestrata Ultimate › Tests › Reference › kernel › test_cli_watch

Tests reference — tests/kernel/test_cli_watch.py

Module of tests/kernel, split out because the directory page would be too large.

Prose pending.

tests/kernel/test_cli_watch.py

source · 31 tests · 676 lines

Tests for kernel/cli_watch.py + the orchestrata watch command wired

Covers: core.base.traces, gateway.config, gateway.server, kernel.cli_client, kernel.cli_main, kernel.cli_watch, kernel.pipeline_events

Kind Name Line Description
class TestIsTerminalEvent 129
method TestIsTerminalEvent.test_true_for_complete 130
method TestIsTerminalEvent.test_true_for_cancelled 133
method TestIsTerminalEvent.test_false_for_non_terminal_type 136
method TestIsTerminalEvent.test_false_when_event_type_missing 139
method TestIsTerminalEvent.test_terminal_set_holds_exactly_the_two_documented_members 142
class TestRenderEventLine 151
method TestRenderEventLine.test_includes_volk_and_driver_when_present 152
method TestRenderEventLine.test_omits_volk_driver_and_data_when_absent 168
method TestRenderEventLine.test_falls_back_to_placeholder_when_timestamp_and_type_missing 181
class TestNormalizeReplayEntry 186
method TestNormalizeReplayEntry.test_decodes_json_data_and_stringified_iteration 187
method TestNormalizeReplayEntry.test_handles_malformed_data_and_iteration_gracefully 203
method TestNormalizeReplayEntry.test_empty_data_string_becomes_empty_dict 209
method TestNormalizeReplayEntry.test_carries_driver_field_when_present 213
class TestNormalizeLivePayload 220
method TestNormalizeLivePayload.test_passthrough_already_decoded_fields 221
method TestNormalizeLivePayload.test_non_dict_data_and_non_int_iteration_default_safely 235
class TestExtractLiveEventA8 248 A8: watch reads live events as JSON-RPC NOTIFICATIONS -- no id
method TestExtractLiveEventA8.test_renders_frame_that_carries_no_id 253
method TestExtractLiveEventA8.test_rejects_a_frame_that_carries_an_id 277
method TestExtractLiveEventA8.test_rejects_a_notification_on_a_different_topic 287
method TestExtractLiveEventA8.test_rejects_missing_or_non_dict_params 295
method TestExtractLiveEventA8.test_rejects_non_dict_payload 302
class TestIngressProofA6 312
method TestIngressProofA6.test_cli_watch_module_imports_no_redis_client 313
class TestStreamThreadEventsEndToEnd 334
method TestStreamThreadEventsEndToEnd.test_prints_backlog_then_live_and_stops_on_terminal 335
method TestStreamThreadEventsEndToEnd.test_count_is_forwarded_to_gateway_replay 365
class TestWatchCommand 385 CLI-level smoke tests for the watch command's flag wiring, against
method TestWatchCommand.test_prints_backlog_and_exits_zero_on_terminal 390
method TestWatchCommand.test_json_mode_emits_one_json_line_per_event 407
class TestWatchSigint 427
method TestWatchSigint.test_exits_cleanly_on_sigint_no_traceback 428
class TestCallRpcRealRpcError 483 Direct coverage of _call_rpc's JSON-RPC error path -- the same
method TestCallRpcRealRpcError.test_unknown_method_raises_clean_click_exception 489
class TestStreamThreadEventsConnectionRefused 518 The unreachable-gateway error path (REQ-000-097: clean exception, no
method TestStreamThreadEventsConnectionRefused.test_raises_clean_click_exception_when_gateway_unreachable 522
class TestStreamThreadEventsAuthFailure 537 A token minted with the real environment's JWT_SECRET must fail
method TestStreamThreadEventsAuthFailure.test_mismatched_secret_raises_clean_click_exception 543
class TestStreamThreadEventsDedup 567 The (timestamp, event_type) dedup guard -- forced deterministically
method TestStreamThreadEventsDedup.test_backlog_dedups_entries_sharing_timestamp_and_event_type 573
method TestStreamThreadEventsDedup.test_live_tail_dedups_a_duplicate_notification 617
class TestLiveFramesDrainsPendingBeforeSocket 661 _live_frames must exhaust pending before it ever touches ws --
method TestLiveFramesDrainsPendingBeforeSocket.test_drains_pending_without_touching_the_socket 666