Skip to content

Commit 358aa90

Browse files
Updated classify single functional test for intended behaviour (#130)
* Updated classify single for new behaviour * revert: remove unintentional uv.lock update --------- Co-authored-by: Carl Patchett <carl.patchett@kroll.com>
1 parent 0c6e85a commit 358aa90

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

tests/functional/test_classify_single.py

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,13 @@ async def test_classify_single(
3737
msg = f"Image Result Error: {result.error.message}"
3838
pytest.fail(msg)
3939

40-
found_hash_check = False
41-
40+
# The WebIQ hash check runs against a 250ms budget and is abandoned
41+
# if it exceeds it, in which case no KnownCSAM-* classification is
42+
# emitted. Its presence is therefore not guaranteed, but when it is
43+
# present the test image must be a clean no-match (weight 0.0).
4244
for classification in result.classifications:
4345
if classification.label.startswith("KnownCSAM-"):
4446
assert classification.weight == 0.0
45-
found_hash_check = True
46-
break
47-
48-
assert found_hash_check, "No KnownHash- classification found"
4947

5048
assert [
5149
classification

0 commit comments

Comments
 (0)