Orchestrata Ultimate › Tests › Reference › test_cxp
Tests reference — tests/test_cxp.py
Module of tests, split out because the directory page would be too large.
Prose pending.
tests/test_cxp.py
source · 120 tests · 1032 lines
Tests for orchestrata_ultimate.cxp — Cross-agent eXchange Protocol.
Covers: cxp.constants, cxp.delivery_status, cxp.exceptions, cxp.headers, cxp.json_serializer, cxp.priority, cxp.schema, cxp.threads, cxp.types, cxp.version, cxp.version_compat, cxp.work_status, core.packet/ (package)
| Kind | Name | Line | Description |
|---|---|---|---|
| function | test_packet_creation_basic |
123 | |
| function | test_packet_auto_generates_message_id |
134 | |
| function | test_packet_auto_generates_thread_id |
141 | |
| function | test_packet_auto_generates_timestamp |
147 | |
| function | test_packet_requires_from_agent |
152 | |
| function | test_packet_requires_to_agent |
157 | |
| function | test_packet_priority_enum_accepted |
162 | |
| function | test_packet_delivery_attempts_default_zero |
167 | |
| function | test_packet_tags_default_empty_list |
172 | |
| function | test_packet_metadata_default_empty_dict |
177 | |
| function | test_packet_packet_type_default_message |
182 | |
| function | test_packet_expires_at_auto_set_from_ttl |
187 | |
| function | test_packet_invalid_ttl_raises |
194 | |
| function | test_delivery_transitions_dict_structure |
204 | |
| function | test_valid_delivery_transition_queued_to_delivered |
209 | |
| function | test_valid_delivery_transition_queued_to_failed |
216 | |
| function | test_valid_delivery_transition_delivered_to_acknowledged |
223 | |
| function | test_invalid_delivery_transition_queued_to_acknowledged |
232 | |
| function | test_invalid_delivery_transition_acknowledged_to_queued |
239 | |
| function | test_work_transitions_dict_structure |
251 | |
| function | test_valid_work_transition_pending_to_in_progress |
256 | |
| function | test_valid_work_transition_in_progress_to_resolved |
260 | |
| function | test_valid_work_transition_resolved_to_archived |
264 | |
| function | test_valid_work_transition_in_progress_to_pending |
268 | |
| function | test_invalid_work_transition_pending_to_archived |
273 | |
| function | test_invalid_work_transition_archived_to_pending |
277 | |
| function | test_delivery_tracker_initial_state |
286 | |
| function | test_delivery_tracker_set_status_valid |
293 | |
| function | test_delivery_tracker_invalid_transition_raises |
300 | |
| function | test_delivery_tracker_history_records_transitions |
309 | |
| function | test_delivery_tracker_record_failure |
317 | |
| function | test_delivery_tracker_can_retry_initially_true |
325 | |
| function | test_delivery_tracker_increment_retry |
331 | |
| function | test_delivery_tracker_custom_max_attempts |
342 | |
| function | test_work_tracker_initial_state |
355 | |
| function | test_work_tracker_start_work |
362 | |
| function | test_work_tracker_resolve_work |
369 | |
| function | test_work_tracker_archive_work |
377 | |
| function | test_work_tracker_requeue_work |
386 | |
| function | test_work_tracker_invalid_transition_raises |
394 | |
| function | test_work_tracker_history_recorded |
401 | |
| function | test_work_tracker_get_work_duration_none_when_not_started |
409 | |
| function | test_work_tracker_get_work_duration_when_resolved |
415 | |
| function | test_work_tracker_metadata_has_requeue_count |
426 | |
| function | test_thread_manager_create_thread |
440 | |
| function | test_thread_manager_add_to_thread |
448 | |
| function | test_thread_manager_get_thread_metadata |
458 | |
| function | test_thread_manager_close_thread |
467 | |
| function | test_thread_manager_add_to_closed_thread_raises |
476 | |
| function | test_thread_manager_reopen_thread |
485 | |
| function | test_thread_manager_list_active_threads |
495 | |
| function | test_thread_manager_get_thread_count |
506 | |
| function | test_thread_manager_nonexistent_thread_raises |
513 | |
| function | test_json_serializer_round_trip |
524 | |
| function | test_json_serializer_to_json_is_string |
535 | |
| function | test_json_serializer_pretty_mode |
542 | |
| function | test_json_serializer_to_dict_returns_dict |
551 | |
| function | test_json_serializer_from_dict |
559 | |
| function | test_json_serializer_invalid_json_raises |
568 | |
| function | test_json_serializer_preserves_delivery_status |
574 | |
| function | test_json_serializer_preserves_work_status |
581 | |
| function | test_schema_registry_has_cxp_packet |
593 | |
| function | test_schema_registry_get_schema |
598 | |
| function | test_schema_registry_validate_valid_packet |
604 | |
| function | test_schema_registry_validate_missing_field |
623 | |
| function | test_schema_registry_validate_invalid_priority |
643 | |
| function | test_schema_registry_unknown_schema |
662 | |
| function | test_schema_registry_register_custom |
669 | |
| function | test_schema_registry_list_sorted |
677 | |
| function | test_priority_manager_sort_by_priority |
688 | |
| function | test_priority_manager_get_priority_level |
698 | |
| function | test_priority_manager_get_priority_level_background |
704 | |
| function | test_priority_manager_get_priority_level_urgent |
709 | |
| function | test_priority_manager_validate_priority_valid |
714 | |
| function | test_priority_manager_validate_priority_out_of_range |
719 | |
| function | test_priority_manager_clamp_priority |
725 | |
| function | test_priority_names_dict |
732 | |
| function | test_default_priorities_has_message |
738 | |
| function | test_validate_uuid_valid |
747 | |
| function | test_validate_uuid_invalid |
752 | |
| function | test_validate_volk_alias_valid |
756 | |
| function | test_validate_volk_alias_invalid |
760 | |
| function | test_validate_subject_valid |
765 | |
| function | test_validate_subject_empty |
769 | |
| function | test_validate_subject_too_long |
773 | |
| function | test_header_manager_validate_all_headers |
778 | |
| function | test_protocol_version_parse |
790 | |
| function | test_protocol_version_current |
797 | |
| function | test_protocol_version_equality |
801 | |
| function | test_protocol_version_less_than |
807 | |
| function | test_protocol_version_greater_than |
813 | |
| function | test_protocol_version_is_compatible_same_major |
819 | |
| function | test_protocol_version_not_compatible_diff_major |
825 | |
| function | test_parse_version_function |
831 | |
| function | test_protocol_version_to_dict |
837 | |
| function | test_version_checker_compatible |
850 | |
| function | test_version_checker_warn_minor_diff |
856 | |
| function | test_version_checker_incompatible_diff_major |
862 | |
| function | test_version_checker_negotiate |
868 | |
| function | test_version_checker_supported_versions |
874 | |
| function | test_volk_aliases_is_dict |
885 | |
| function | test_volk_roles_is_dict |
890 | |
| function | test_thread_metadata_creation |
894 | |
| function | test_thread_metadata_add_participant |
909 | |
| function | test_thread_metadata_to_dict |
924 | |
| function | test_routing_result_creation |
940 | |
| function | test_routing_result_to_dict |
950 | |
| function | test_protocol_version_constant |
966 | |
| function | test_protocol_name_constant |
970 | |
| function | test_payload_max_bytes |
974 | |
| function | test_subject_max_length |
978 | |
| function | test_max_delivery_attempts |
982 | |
| function | test_default_retry_delay |
986 | |
| function | test_thread_max_messages_positive |
990 | |
| function | test_cxp_error_base |
999 | |
| function | test_delivery_error_inherits_cxp_error |
1005 | |
| function | test_max_retries_exceeded_error |
1010 | |
| function | test_state_transition_error |
1015 | |
| function | test_thread_not_found_error |
1025 | |
| function | test_thread_closed_error |
1030 |