Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set the serialized_aliases Argument of setup_databases. #1167

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

xmatos-so
Copy link

The serialized_aliases argument of the setup_databases function determines what subset of aliases test databases should have their state serialized to allow usage of the serialized_rollback feature. If it's not provided, it defaults to aliases.

Django 5 removed the SERIALIZE test setting, as it can be inferred from the databases with the serialized_rollback option enabled. Django's default test runner, DiscoverRunner, uses logic similar to this to build the serialized_aliases set and pass it to setup_databases, as implemented in django.test.runner.DiscoverRunner.run_tests.

@xmatos-so xmatos-so marked this pull request as draft January 10, 2025 14:08
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.

2 participants