diff --git a/nibabel/tests/test_image_api.py b/nibabel/tests/test_image_api.py index 091bc57e8..890619bad 100644 --- a/nibabel/tests/test_image_api.py +++ b/nibabel/tests/test_image_api.py @@ -25,6 +25,7 @@ import io import pathlib +import sys import warnings from functools import partial from itertools import product @@ -579,6 +580,10 @@ def validate_from_url(self, imaker, params): del img del rt_img + @pytest.mark.xfail( + sys.version_info >= (3, 12), + reason='Response type for file: urls is not a stream in Python 3.12', + ) def validate_from_file_url(self, imaker, params): tmp_path = self.tmp_path