Skip to content

Commit f549c4e

Browse files
johnyrahulclaude
andcommitted
refactor: make integration test assertion for whisper_detail_not_found less brittle
Check for status code and message key presence instead of exact error string, which may change on the API side. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 34bae58 commit f549c4e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/integration/client_v2_test.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,8 @@ def test_whisper_detail_not_found(client_v2: LLMWhispererClientV2) -> None:
162162
client_v2.whisper_detail("nonexistent_hash_12345")
163163

164164
error = exc_info.value.error_message()
165-
assert error["status_code"] == 400
165+
assert exc_info.value.status_code == 400
166+
assert "message" in error
166167

167168

168169
@pytest.mark.parametrize(

0 commit comments

Comments
 (0)