From f42d9c562d344ae9beb7ea5ba1238f5d9c19601c Mon Sep 17 00:00:00 2001 From: Nicolas Hug Date: Mon, 9 Oct 2023 10:02:02 +0100 Subject: [PATCH] Put pytestmark at top of file --- test/test_transforms_v2.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) 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)]