This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse the repository at this point in the history
Bug 1228013 - Add a test for missing Django migrations
This test checks that `./manage.py makemigrations` was run, and the resultant migrations file committed to the repo, since the last time the Django models were updated. Django 1.8 only supports an `exit_code` option, which unhelpfully makes the command `sys.exit(1)` if there are *no* missing migrations, when we're more interested in the opposite. As such, we have to confirm that it does exit 1 (which causes a `SystemExit` exception). On Django master they've replaced `exit_code` with `check_changes` that inverts the check, which we should switch to once we're using a version of Django that includes that fix.
- Loading branch information
Showing 1 changed file with 11 additions and 0 deletions.