devkit_ui.missions.test_store

Classes

TestMissionStoreEditing([methodName])

TestMissionStoreRunHistory([methodName])

TestMissionStoreScheduling([methodName])

Scheduling reads last_run_* fields, so the missions are loaded from a prepared YAML file.

TestValidateMission([methodName])

class devkit_ui.missions.test_store.TestMissionStoreEditing(methodName='runTest')[source]

Bases: TestCase

setUp() → None[source]

Hook method for setting up the test fixture before exercising it.

test_add_cleans_the_name_and_mirrors_state_onto_the_node() → None[source]
test_add_rejects_invalid_mission_and_reports_why() → None[source]
test_attach_initialises_node_state() → None[source]
test_close_is_a_no_op_for_the_yaml_backend() → None[source]
test_close_releases_the_sqlite_connection() → None[source]
test_delete_removes_the_mission() → None[source]
test_delete_unknown_mission_reports_not_found() → None[source]
test_set_active_toggles_the_mission() → None[source]
test_unknown_mission_has_no_due_time() → None[source]
test_unsupported_file_extension_is_rejected() → None[source]
test_update_changes_mutable_fields() → None[source]
test_update_rejects_immutable_fields() → None[source]
test_update_that_fails_validation_is_rejected() → None[source]
test_update_unknown_mission_reports_not_found() → None[source]
test_update_with_blank_name_falls_back_to_the_id() → None[source]
class devkit_ui.missions.test_store.TestMissionStoreRunHistory(methodName='runTest')[source]

Bases: TestCase

setUp() → None[source]

Hook method for setting up the test fixture before exercising it.

test_failed_run_keeps_the_mission_active_and_queued_for_retry() → None[source]
test_record_run_for_unknown_mission_reports_not_found() → None[source]
test_record_run_mirrors_state_onto_the_node() → None[source]
test_recorded_run_is_restored_after_reopening_the_store() → None[source]
test_reset_for_unknown_mission_reports_not_found() → None[source]
test_reset_rearms_a_completed_mission() → None[source]
test_reset_state_is_restored_after_reopening_the_store() → None[source]
test_successful_one_shot_run_is_recorded_and_deactivates_the_mission() → None[source]
test_successful_recurring_run_stays_active_and_waits_for_its_interval() → None[source]
class devkit_ui.missions.test_store.TestMissionStoreScheduling(methodName='runTest')[source]

Bases: TestCase

Scheduling reads last_run_* fields, so the missions are loaded from a prepared YAML file.

setUp() → None[source]

Hook method for setting up the test fixture before exercising it.

test_completed_one_shot_has_no_due_time() → None[source]
test_failed_mission_reports_the_retry_sentinel() → None[source]
test_inactive_mission_has_no_due_time() → None[source]
test_malformed_timestamp_is_treated_as_never_run() → None[source]
test_never_run_mission_is_due_now() → None[source]
test_recurring_mission_past_its_interval_is_due_now() → None[source]
test_recurring_mission_reports_hours_until_the_interval_elapses() → None[source]
test_today_queue_lists_only_due_active_missions_with_valid_actions() → None[source]
class devkit_ui.missions.test_store.TestValidateMission(methodName='runTest')[source]

Bases: TestCase

test_no_rows_is_rejected() → None[source]
test_non_integer_repeat_is_rejected() → None[source]
test_non_positive_repeat_is_rejected() → None[source]
test_uncleaned_name_is_rejected() → None[source]
test_unknown_action_is_rejected() → None[source]
test_valid_mission_has_no_error() → None[source]
test_valid_mission_without_name_or_repeat_has_no_error() → None[source]