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

Consider adding django-test-migrations #290

Closed
sobolevn opened this issue Nov 25, 2019 · 2 comments
Closed

Consider adding django-test-migrations #290

sobolevn opened this issue Nov 25, 2019 · 2 comments

Comments

@sobolevn
Copy link
Contributor

I know that django-celery-beat had some issues with migrations back in the days.

I am proposing to add the support of testing migration files to prevent errors like:

  1. Inconsistent migrations order, like here: https://github.com/celery/django-celery-beat/blob/master/django_celery_beat/migrations/0006_periodictask_priority.py#L9
  2. Possibly incompatible changes to existing models in a complex migrations, like this one: https://github.com/celery/django-celery-beat/blob/master/django_celery_beat/migrations/0010_auto_20190429_0326.py#L22

This can be done with the help of https://github.com/wemake-services/django-test-migrations

I would be glad to hear your feedback if any.

@liquidpele
Copy link
Contributor

I added tests because of those issues, see https://github.com/celery/django-celery-beat/blob/master/t/unit/test_models.py#L14

Also the tox file now does these tests starting from various versions so there's full coverage.

@auvipy
Copy link
Member

auvipy commented Nov 25, 2021

new migrations tests are added to the project

@auvipy auvipy closed this as completed Nov 25, 2021
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

No branches or pull requests

3 participants