From 8cb985ac8fc2df52183748fb2fb0cf6ac065a431 Mon Sep 17 00:00:00 2001 From: Ken Odegard Date: Wed, 14 Aug 2024 11:14:55 -0500 Subject: [PATCH] Correct testing per deprecation/removal in conda-build (#179) * Correct testing per deprecation in conda-build * Elevate warnings to catch deprecations in the future --- pyproject.toml | 11 +++++++++++ tests/conftest.py | 3 --- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 97fc578..4782106 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,6 +53,17 @@ Home = "https://github.com/conda/conda-index" [tool.pytest.ini_options] minversion = "7.0" testpaths = ["tests"] +filterwarnings = [ + # elevate conda's deprecated warning to an error + "error::PendingDeprecationWarning:conda", + "error::DeprecationWarning:conda", + # elevate conda-build's deprecated warning to an error + "error::PendingDeprecationWarning:conda_build", + "error::DeprecationWarning:conda_build", + # elevate conda-index's deprecated warning to an error + "error::PendingDeprecationWarning:conda_index", + "error::DeprecationWarning:conda_index", +] [tool.coverage.run] concurrency = ["multiprocessing", "thread"] diff --git a/tests/conftest.py b/tests/conftest.py index cb7727a..3f77c45 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -16,7 +16,6 @@ filename_hashing_default, ignore_verify_codes_default, no_rewrite_stdout_env_default, - noarch_python_build_age_default, ) from conda_build.metadata import MetaData from conda_build.utils import check_call_env, copy_into, prepend_bin_path @@ -108,7 +107,6 @@ def boolify(v): _src_cache_root=_src_cache_root_default, error_overlinking=boolify(error_overlinking_default), error_overdepending=boolify(error_overdepending_default), - noarch_python_build_age=noarch_python_build_age_default, enable_static=boolify(enable_static_default), no_rewrite_stdout_env=boolify(no_rewrite_stdout_env_default), ignore_verify_codes=ignore_verify_codes_default, @@ -118,7 +116,6 @@ def boolify(v): assert result.no_rewrite_stdout_env is False assert result._src_cache_root is None assert result.src_cache_root == testing_workdir - assert result.noarch_python_build_age == 0 return result