← Về thư mục
tests/test_orchestration_session.py
- _isolates_fake_backend · function · L58-L61 — def _isolates_fake_backend(backend: str) -> bool
- test_session_isolation_capability_is_optional_and_fails_closed · function · L64-L82 — def test_session_isolation_capability_is_optional_and_fails_closed()
- _Isolated · class · L65-L67 — class _Isolated
- isolates_session_credentials · method · L66-L67 — def isolates_session_credentials(self)
- _Raising · class · L69-L71 — class _Raising
- isolates_session_credentials · method · L70-L71 — def isolates_session_credentials(self)
- _HostileLookup · class · L73-L76 — class _HostileLookup
- isolates_session_credentials · method · L75-L76 — def isolates_session_credentials(self)
- FakeBackend · class · L88-L118 — class FakeBackend
- init · method · L95-L99 — def init(self)
- submit · method · L101-L106 — def submit(self, *, allocation, spec, profile)
- observe · method · L108-L109 — def observe(self, allocation)
- cancel · method · L111-L112 — def cancel(self, allocation, *, reason)
- find_by_token · method · L114-L115 — def find_by_token(self, token)
- diagnostics · method · L117-L118 — def diagnostics(self)
- _handle · function · L121-L124 — def _handle(allocation)
- FakeGateway · class · L127-L150 — class FakeGateway
- init · method · L131-L132 — def init(self)
- arrive · method · L134-L135 — def arrive(self, allocation_id, epoch, registration="reg")
- await_worker · method · L137-L141 — def await_worker(self, allocation_id, epoch, *, timeout_s)
- await_workers · method · L143-L150 — def await_workers(self, allocation_id, epoch, *, expected, timeout_s)
- store · function · L154-L159 — def store(tmp_path)
- manager · function · L163-L171 — def manager(store, tmp_path)
- test_manager_precreates_private_workspace_root_before_any_workload · function · L174-L195 — def test_manager_precreates_private_workspace_root_before_any_workload(store, tmp_path)
- _FakeKernel · class · L198-L203 — class _FakeKernel
- init · method · L199-L200 — def init(self)
- shutdown · method · L202-L203 — def shutdown(self)
- test_three_of_four_conditions_is_not_ready · function · L209-L229 — def test_three_of_four_conditions_is_not_ready()
- test_readiness_names_the_missing_condition_not_just_no · function · L232-L244 — def test_readiness_names_the_missing_condition_not_just_no()
- test_a_granted_allocation_alone_does_not_make_a_session_ready · function · L247-L260 — def test_a_granted_allocation_alone_does_not_make_a_session_ready(store, manager)
- test_all_four_conditions_make_it_ready · function · L263-L273 — def test_all_four_conditions_make_it_ready(store, manager)
- test_a_worker_from_the_previous_epoch_does_not_satisfy_this_one · function · L276-L290 — def test_a_worker_from_the_previous_epoch_does_not_satisfy_this_one(store, manager)
- test_manager_refuses_unisolated_session_before_durable_or_filesystem_state · function · L296-L323 — def test_manager_refuses_unisolated_session_before_durable_or_filesystem_state( store, tmp_path )
- test_attempt_preparer_refuses_old_unisolated_workload_before_credential_write · function · L326-L350 — def test_attempt_preparer_refuses_old_unisolated_workload_before_credential_write( store, manager, tmp_path )
- test_old_unisolated_worker_is_never_awaited_adopted_or_given_a_kernel · function · L353-L394 — def test_old_unisolated_worker_is_never_awaited_adopted_or_given_a_kernel( store, tmp_path )
- _TrackingGateway · class · L358-L367 — class _TrackingGateway(FakeGateway)
- init · method · L359-L361 — def init(self)
- await_workers · method · L363-L367 — def await_workers(self, allocation_id, epoch, *, expected, timeout_s)
- test_the_submitted_spec_carries_a_path_and_the_stored_one_carries_nothing · function · L397-L435 — def test_the_submitted_spec_carries_a_path_and_the_stored_one_carries_nothing( store, manager, tmp_path )
- test_each_attempt_gets_its_own_credential · function · L438-L474 — def test_each_attempt_gets_its_own_credential(store, manager)
- test_a_batch_workload_is_submitted_exactly_as_written · function · L477-L498 — def test_a_batch_workload_is_submitted_exactly_as_written(store, manager)
- test_a_lost_session_recovers_into_a_new_epoch_without_rewriting_history · function · L504-L551 — def test_a_lost_session_recovers_into_a_new_epoch_without_rewriting_history( store, manager )
- test_recovery_tells_the_session_its_kernel_memory_is_gone · function · L554-L572 — def test_recovery_tells_the_session_its_kernel_memory_is_gone(store, manager)
- test_recovery_is_bounded · function · L575-L604 — def test_recovery_is_bounded(store, manager)
- test_a_session_being_cancelled_is_not_recovered · function · L607-L636 — def test_a_session_being_cancelled_is_not_recovered(store, manager)
- _Clock · class · L642-L656 — class _Clock
- init · method · L649-L650 — def init(self, start_ms=1_700_000_000_000)
- call · method · L652-L653 — def call(self)
- advance_s · method · L655-L656 — def advance_s(self, seconds)
- lease_clock · function · L660-L664 — def lease_clock(store)
- test_a_healthy_worker_does_not_keep_a_session_alive · function · L667-L693 — def test_a_healthy_worker_does_not_keep_a_session_alive(store, manager, lease_clock)
- test_a_user_executing_something_renews_the_lease · function · L696-L713 — def test_a_user_executing_something_renews_the_lease(store, manager, lease_clock)
- test_a_touch_after_the_sweep_snapshot_wins_the_expiry_cas · function · L716-L749 — def test_a_touch_after_the_sweep_snapshot_wins_the_expiry_cas( store, manager, lease_clock, monkeypatch )
- touch_then_expire · function · L738-L740 — def touch_then_expire(lease, *, now_ms, reason)
- test_the_maximum_lifetime_cannot_be_renewed_past · function · L752-L771 — def test_the_maximum_lifetime_cannot_be_renewed_past(store, manager, lease_clock)
- test_a_touch_racing_the_maximum_lifetime_cannot_renew_it · function · L774-L802 — def test_a_touch_racing_the_maximum_lifetime_cannot_renew_it( store, manager, lease_clock, monkeypatch )
- touch_then_expire · function · L790-L793 — def touch_then_expire(lease, *, now_ms, reason)
- test_an_expired_lease_is_swept_once · function · L805-L817 — def test_an_expired_lease_is_swept_once(store, manager, lease_clock)
- test_the_reclaimer_reports_whether_it_is_actually_sweeping · function · L820-L838 — def test_the_reclaimer_reports_whether_it_is_actually_sweeping(store)
- test_a_session_keeps_one_workload_across_a_recovery · function · L844-L852 — def test_a_session_keeps_one_workload_across_a_recovery(store, manager)
- test_asking_twice_for_a_session_returns_the_same_workload · function · L855-L862 — def test_asking_twice_for_a_session_returns_the_same_workload(store, manager)
- test_a_terminal_binding_is_atomically_replaced_by_a_new_workload · function · L865-L878 — def test_a_terminal_binding_is_atomically_replaced_by_a_new_workload(store, manager)
- test_session_workload_binding_and_lease_roll_back_together · function · L881-L894 — def test_session_workload_binding_and_lease_roll_back_together(store, manager)
- test_concurrent_session_requests_publish_only_one_workload · function · L897-L938 — def test_concurrent_session_requests_publish_only_one_workload( store, manager, monkeypatch )
- delayed_create · function · L906-L914 — def delayed_create(**kwargs)
- request · function · L919-L924 — def request()
- test_releasing_a_session_asks_for_a_stop_and_ends_the_lease · function · L941-L949 — def test_releasing_a_session_asks_for_a_stop_and_ends_the_lease(store, manager)
- test_session_cleanup_candidates_are_complete_durable_intents · function · L952-L991 — def test_session_cleanup_candidates_are_complete_durable_intents(store, manager)
- test_session_release_rolls_back_stop_lease_and_binding_together · function · L994-L1010 — def test_session_release_rolls_back_stop_lease_and_binding_together(store, manager)
- test_the_reason_a_session_was_reclaimed_survives_the_backend · function · L1013-L1050 — def test_the_reason_a_session_was_reclaimed_survives_the_backend(store, manager)
- test_checkpoint_recovery_is_refused_rather_than_approximated · function · L1056-L1075 — def test_checkpoint_recovery_is_refused_rather_than_approximated(store, manager)
- test_an_unknown_strategy_is_refused_the_same_way · function · L1078-L1088 — def test_an_unknown_strategy_is_refused_the_same_way(store, manager)
- test_the_supported_strategy_is_the_default · function · L1091-L1100 — def test_the_supported_strategy_is_the_default(store, manager)