diff --git a/test/test_transforms_v2.py b/test/test_transforms_v2.py index 9d48b799240..4f8d0027bd6 100644 --- a/test/test_transforms_v2.py +++ b/test/test_transforms_v2.py @@ -52,6 +52,10 @@ from torchvision.transforms.v2.functional._utils import _get_kernel, _register_kernel_internal +# turns all warnings into errors for this module +pytestmark = pytest.mark.filterwarnings("error") + + @pytest.fixture(autouse=True) def fix_rng_seed(): set_rng_seed(0) @@ -539,10 +543,6 @@ def affine_bounding_boxes(bounding_boxes): ) -# turns all warnings into errors for this module -pytestmark = pytest.mark.filterwarnings("error") - - class TestResize: INPUT_SIZE = (17, 11) OUTPUT_SIZES = [17, [17], (17,), [12, 13], (12, 13)]