Skip to content

fix(test): add @pytest.mark.asyncio to TestUpdateColumnAllowlist - #109

Open
github-actions[bot] wants to merge 1 commit into
fix/sec-83-banditfrom
claude-auto-fix-ci-fix/sec-83-bandit-30052939687
Open

fix(test): add @pytest.mark.asyncio to TestUpdateColumnAllowlist#109
github-actions[bot] wants to merge 1 commit into
fix/sec-83-banditfrom
claude-auto-fix-ci-fix/sec-83-bandit-30052939687

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Root cause

pytest-asyncio is running in STRICT mode during CI. The asyncio_mode = auto setting in pytest.ini sits under a [tool:pytest] section, which is only valid in setup.cfgpytest.ini only recognises the [pytest] section. As a result, the setting is silently ignored and pytest-asyncio falls back to STRICT mode.

In STRICT mode every async def test function must carry an explicit @pytest.mark.asyncio decorator (or inherit one from a class-level decorator). All other async test classes in this repo (TestMigrationManager, TestRAGManager, TestGoalsService) already follow this convention; the new TestUpdateColumnAllowlist class introduced in PR #98 was missing the decorator.

Fix

Added @pytest.mark.asyncio at the class level in tests/test_database_update_allowlist.py — identical to the pattern used by every other async test class in the project.

References

Fixes failing test-backend / Run database tests step in CI run https://github.com/izzywdev/FuzeAgent/actions/runs/30052681664.
Companion to #98.

🤖 Generated with Claude Code

pytest-asyncio runs in STRICT mode (the [tool:pytest] asyncio_mode=auto
setting in pytest.ini is not recognised by the [pytest] parser).  All
other async test classes in this repo (TestMigrationManager,
TestRAGManager) carry the class-level @pytest.mark.asyncio decorator;
the new allowlist test class was missing it, causing the four async
methods to fail with "async def functions are not natively supported".

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@github-actions
github-actions Bot requested a review from izzywdev as a code owner July 23, 2026 23:23
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.

0 participants