Skip to content

Use pytest-beartype-tests plugin#2966

Merged
adamtheturtle merged 3 commits intomainfrom
use-pytest-beartype-tests-plugin
Apr 19, 2026
Merged

Use pytest-beartype-tests plugin#2966
adamtheturtle merged 3 commits intomainfrom
use-pytest-beartype-tests-plugin

Conversation

@adamtheturtle
Copy link
Copy Markdown
Member

@adamtheturtle adamtheturtle commented Apr 19, 2026

This PR adds the pytest-beartype-tests dev dependency and removes redundant pytest_collection_modifyitems / @beartype wiring from conftest where it duplicated the plugin.

The plugin registers via pytest11 and applies @beartype to collected test functions, matching the previous local hook behavior (see the upstream README).


Note

Low Risk
Low risk: changes are confined to the test configuration and dev dependencies, but could affect CI/test behavior if the plugin differs from the previous hook.

Overview
Replaces the local pytest_collection_modifyitems + @beartype wiring in conftest.py with the pytest-beartype-tests plugin to apply runtime type checking to collected tests.

Adds pytest-beartype-tests to dev dependencies (with a pinned git uv source) and cleans up related config (adds an empty [dependency-groups] dev entry and removes the obsolete Vulture ignore for pytest_collection_modifyitems).

Reviewed by Cursor Bugbot for commit 95b5a46. Bugbot is set up for automated code reviews on this repo. Configure here.

Replace manual pytest_collection_modifyitems hooks with the
https://github.com/adamtheturtle/pytest-beartype-tests dev dependency.
Use git+https dependency until the next PyPI release includes
adamtheturtle/pytest-beartype-tests@bc81d99.
Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 95b5a46. Configure here.

Comment thread pyproject.toml
urls.Source = "https://github.com/VWS-Python/vws-python"

[dependency-groups]
dev = []
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Empty dependency-groups section adds dead configuration

Low Severity

The newly added [dependency-groups] section with dev = [] is empty and serves no purpose. All dev dependencies live in optional-dependencies.dev, and CI uses uv run --extra=dev. This dead configuration could confuse contributors about where dev dependencies are managed, especially since uv sync installs dependency-groups.dev by default — which here resolves to nothing.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 95b5a46. Configure here.

@adamtheturtle adamtheturtle merged commit ed09493 into main Apr 19, 2026
16 checks passed
@adamtheturtle adamtheturtle deleted the use-pytest-beartype-tests-plugin branch April 19, 2026 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant