Tests
Handlers
Handlers in MatrixCtl are used to handle the communication between the server and the Commands or to load config files.
Fixtures
Create handler fixtures for testing.
YAML
Test the yaml handler.
- tests.matrixctl.handlers.test_yaml.test_get_ansible_playbook(yaml)[source]
Test ansible -> playbook.
- Return type:
- tests.matrixctl.handlers.test_yaml.test_get_api_domain(yaml)[source]
Test api -> domain.
- Return type:
- tests.matrixctl.handlers.test_yaml.test_get_api_token(yaml)[source]
Test api -> token.
- Return type:
- tests.matrixctl.handlers.test_yaml.test_get_api_username(yaml)[source]
Test api -> username.
- Return type:
- tests.matrixctl.handlers.test_yaml.test_get_ssh_address(yaml)[source]
Test ssh -> address.
- Return type:
Sanitizers
Test the sanitizers.
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_1()[source]
Test valid identifier.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_2()[source]
Test valid identifier with spaces around.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_3()[source]
Test invalid identifier (without $).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_4()[source]
Test invalid identifier (empty str).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_5()[source]
Test missing identifier (None).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_event_identifier_6()[source]
Test wrong type.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_invalid()[source]
Test invalid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_lower_case()[source]
Test valid message type as lowercase string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_avatar_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_avatar_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_create_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_create_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_join_rules_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_join_rules_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_member_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_member_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_message_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_message_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_name_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_name_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_pinned_events_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_pinned_events_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_power_levels_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_power_levels_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_redaction_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_redaction_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_topic_1()[source]
Test valid message type as MessageType.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_m_room_topic_2()[source]
Test valid message type as string.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_none()[source]
Test none case.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_message_type_with_spaces()[source]
Test valid message type as string with spaces around.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_1()[source]
Test valid identifier.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_2()[source]
Test valid identifier with spaces around.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_3()[source]
Test invalid identifier (without $).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_4()[source]
Test invalid identifier (empty str).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_5()[source]
Test missing identifier (None).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_room_identifier_6()[source]
Test wrong type.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_user_identifier_1()[source]
Test valid identifier.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_user_identifier_2()[source]
Test valid identifier with spaces around.
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_user_identifier_3()[source]
Test invalid identifier (without $).
- Return type:
- tests.matrixctl.test_sanitizers.test_sanitize_user_identifier_4()[source]
Test invalid identifier (empty str).
- Return type: