(self)
| 190 | """Test CommandResultMessage""" |
| 191 | |
| 192 | def test_success_result(self) -> None: |
| 193 | msg = CommandResultMessage( |
| 194 | id="req-123", |
| 195 | success=True, |
| 196 | data={"isPlaying": True}, |
| 197 | ) |
| 198 | d = msg.to_dict() |
| 199 | |
| 200 | assert d["type"] == "COMMAND_RESULT" |
| 201 | assert d["id"] == "req-123" |
| 202 | assert d["success"] is True |
| 203 | assert d["data"] == {"isPlaying": True} |
| 204 | |
| 205 | def test_error_result(self) -> None: |
| 206 | msg = CommandResultMessage( |
nothing calls this directly
no test coverage detected