From 7de4505e31ffd664416a5b55d3d151b8f18e8df5 Mon Sep 17 00:00:00 2001 From: Kai Chappell Date: Wed, 4 Feb 2026 00:43:20 +0000 Subject: [PATCH] fix(pytest-plugin): remove duplicate plugin registration in tests The pytest plugin is already loaded via the entry point, so explicitly declaring it in conftest causes a duplicate registration error. --- changelog.md | 1 + tests/test_pytest_plugin/test_plugin.py | 11 +++++------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/changelog.md b/changelog.md index 3f7b7e8..22e1dd1 100644 --- a/changelog.md +++ b/changelog.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fixed unbounded cache growth in `SemanticSimilarity` by implementing LRU eviction with configurable max size - Fixed mutable list aliasing in `AllOf` and `AnyOf` composite validators - Fixed regex pattern validation in `ContainsValidator` and `ExcludesValidator` to fail at init time rather than during `check()` +- Fixed pytest plugin tests failing with duplicate plugin registration error ### Added diff --git a/tests/test_pytest_plugin/test_plugin.py b/tests/test_pytest_plugin/test_plugin.py index 6efa2c5..f70b952 100644 --- a/tests/test_pytest_plugin/test_plugin.py +++ b/tests/test_pytest_plugin/test_plugin.py @@ -5,12 +5,11 @@ import pytest @pytest.fixture def plugin_pytester(pytester: pytest.Pytester) -> pytest.Pytester: - """Configure pytester to use the veritext plugin.""" - pytester.makeconftest( - """ - pytest_plugins = ['veritext.pytest_plugin'] - """ - ) + """Configure pytester to use the veritext plugin. + + Note: The plugin is already loaded via the entry point in pyproject.toml, + so no explicit pytest_plugins declaration is needed. + """ return pytester