Skip to content

Commit 20bfd38

Browse files
committed
Fixed failing tests.
1 parent 8821960 commit 20bfd38

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

tests/models/sam2_video/test_processor_sam2_video.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,5 +149,5 @@ def test_post_process_masks(self):
149149
self.assertEqual(masks[0].shape, (1, 3, 1764, 2646))
150150

151151
dummy_masks = [[1, 0], [0, 1]]
152-
with self.assertRaises(ValueError):
152+
with self.assertRaises(TypeError):
153153
masks = processor.post_process_masks(dummy_masks, np.array(original_sizes))

tests/test_tokenization_mistral_common.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -945,7 +945,7 @@ def test_appsly_chat_template_with_truncation(self):
945945

946946
# Test 3:
947947
# assert truncation is boolean
948-
with self.assertRaises(ValueError):
948+
with self.assertRaises(TypeError):
949949
self.tokenizer.apply_chat_template(
950950
conversation, tokenize=True, truncation=TruncationStrategy.LONGEST_FIRST, max_length=20
951951
)
@@ -1189,7 +1189,7 @@ def test_batch_apply_chat_template_with_truncation(
11891189

11901190
# Test 3:
11911191
# assert truncation is boolean
1192-
with self.assertRaises(ValueError):
1192+
with self.assertRaises(TypeError):
11931193
self.tokenizer.apply_chat_template(
11941194
self.fixture_conversations, tokenize=True, truncation=TruncationStrategy.LONGEST_FIRST, max_length=20
11951195
)

0 commit comments

Comments
 (0)