Skip to content

Integrate tests via VSCode instead of PyCharm - #1230

Open
peterthomassen wants to merge 2 commits into
mainfrom
20260812_fix_test_mail_backends
Open

Integrate tests via VSCode instead of PyCharm#1230
peterthomassen wants to merge 2 commits into
mainfrom
20260812_fix_test_mail_backends

Conversation

@peterthomassen

Copy link
Copy Markdown
Member

No description provided.

peterthomassen and others added 2 commits August 13, 2026 03:20
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Under pytest (e.g. running tests from VSCode), test modules are
imported during collection, before pytest-django's fixture patches
EMAIL_BACKEND to the locmem test backend. The old class attribute
captured the real EMAIL_BACKEND too early, breaking test_lanes.

PyCharm's "Django tests" runner and manage.py test aren't affected:
DiscoverRunner patches EMAIL_BACKEND before importing test modules.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@peterthomassen
peterthomassen force-pushed the 20260812_fix_test_mail_backends branch from 4e4f5a8 to 5914471 Compare August 13, 2026 01:21
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