Skip to content

Commit b0c4c46

Browse files
committed
test: specify warning message for userwarning
1 parent ce80877 commit b0c4c46

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

nibabies/utils/tests/test_bids.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,5 +78,5 @@ def test_get_age_from_tsv_warning(tmp_path):
7878
dual_participants = {'participant_id': ['sub-1', 'sub-2', 'sub-2']}
7979
create_tsv({**dual_participants, **age_months}, tsv_file)
8080

81-
with pytest.warns(UserWarning):
81+
with pytest.warns(UserWarning, match='Multiple matches for participant_id:sub-2'):
8282
_get_age_from_tsv(tsv_file, 'participant_id', 'sub-2')

0 commit comments

Comments
 (0)