diff --git a/setup.cfg b/setup.cfg index d091897..3ccb7c1 100644 --- a/setup.cfg +++ b/setup.cfg @@ -47,7 +47,8 @@ universal = 1 universal = 1 [tool:pytest] -addopts = --strict +addopts = --strict-markers --strict-config -v -r sxfE --color=yes +xfail_strict = true python_files = test_*.py testpaths = xarray_extras/tests diff --git a/xarray_extras/kernels/np_to_csv_py.py b/xarray_extras/kernels/np_to_csv_py.py index 35151bf..c1ea6d6 100755 --- a/xarray_extras/kernels/np_to_csv_py.py +++ b/xarray_extras/kernels/np_to_csv_py.py @@ -4,13 +4,15 @@ from __future__ import annotations import ctypes +import warnings import numpy as np from xarray_extras.kernels import np_to_csv # type: ignore -np_to_csv = np.ctypeslib.load_library("np_to_csv", np_to_csv.__file__) - +with warnings.catch_warnings(): + warnings.simplefilter("ignore", category=DeprecationWarning) + np_to_csv = np.ctypeslib.load_library("np_to_csv", np_to_csv.__file__) np_to_csv.snprintcsvd.argtypes = [ ctypes.c_char_p, # char * buf diff --git a/xarray_extras/tests/test_cumulatives.py b/xarray_extras/tests/test_cumulatives.py index 400265e..bf30b40 100644 --- a/xarray_extras/tests/test_cumulatives.py +++ b/xarray_extras/tests/test_cumulatives.py @@ -11,7 +11,7 @@ dims=["t", "s"], coords={ "t": numpy.array( - ["1990-12-30", "2000-12-30", "2005-12-30", "2010-12-30"], dtype="