Skip to content

Commit d2ecef4

Browse files
committed
pytest.xfail -> ValueError.
1 parent ea14465 commit d2ecef4

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

tests/lora/utils.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1603,9 +1603,8 @@ def test_lora_fuse_nan(self):
16031603
tower_name for tower_name in possible_tower_names if hasattr(pipe.transformer, tower_name)
16041604
]
16051605
if len(filtered_tower_names) == 0:
1606-
pytest.xfail(
1607-
reason=f"`pipe.transformer` didn't have any of the following attributes: {possible_tower_names}."
1608-
)
1606+
reason=f"`pipe.transformer` didn't have any of the following attributes: {possible_tower_names}."
1607+
raise ValueError(reason)
16091608
for tower_name in filtered_tower_names:
16101609
transformer_tower = getattr(pipe.transformer, tower_name)
16111610
has_attn1 = any("attn1" in name for name in named_modules)

0 commit comments

Comments
 (0)