diff --git a/.travis.yml b/.travis.yml index 7eff80a97e4..c0a19a3434c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,6 +16,8 @@ matrix: script: tox - python: 3.6 env: TOXENV=eslint + - python: 3.6 + env: TOXENV=migrations cache: directories: - ~/.cache/pip diff --git a/readthedocs/gold/migrations/0003_add_missing_model_change_migrations.py b/readthedocs/gold/migrations/0003_add_missing_model_change_migrations.py new file mode 100644 index 00000000000..2e919ac202e --- /dev/null +++ b/readthedocs/gold/migrations/0003_add_missing_model_change_migrations.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.16 on 2018-10-31 11:25 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('gold', '0002_rename_last_4_digits'), + ] + + operations = [ + migrations.AlterField( + model_name='golduser', + name='level', + field=models.CharField(choices=[('v1-org-5', '$5/mo'), ('v1-org-10', '$10/mo'), ('v1-org-15', '$15/mo'), ('v1-org-20', '$20/mo'), ('v1-org-50', '$50/mo'), ('v1-org-100', '$100/mo')], default='v1-org-5', max_length=20, verbose_name='Level'), + ), + ] diff --git a/readthedocs/integrations/migrations/0003_add_missing_model_change_migrations.py b/readthedocs/integrations/migrations/0003_add_missing_model_change_migrations.py new file mode 100644 index 00000000000..a1356c48fa2 --- /dev/null +++ b/readthedocs/integrations/migrations/0003_add_missing_model_change_migrations.py @@ -0,0 +1,60 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.16 on 2018-10-31 11:25 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('integrations', '0002_add-webhook'), + ] + + operations = [ + migrations.CreateModel( + name='BitbucketWebhook', + fields=[ + ], + options={ + 'proxy': True, + 'indexes': [], + }, + bases=('integrations.integration',), + ), + migrations.CreateModel( + name='GenericAPIWebhook', + fields=[ + ], + options={ + 'proxy': True, + 'indexes': [], + }, + bases=('integrations.integration',), + ), + migrations.CreateModel( + name='GitHubWebhook', + fields=[ + ], + options={ + 'proxy': True, + 'indexes': [], + }, + bases=('integrations.integration',), + ), + migrations.CreateModel( + name='GitLabWebhook', + fields=[ + ], + options={ + 'proxy': True, + 'indexes': [], + }, + bases=('integrations.integration',), + ), + migrations.AlterField( + model_name='integration', + name='integration_type', + field=models.CharField(choices=[('github_webhook', 'GitHub incoming webhook'), ('bitbucket_webhook', 'Bitbucket incoming webhook'), ('gitlab_webhook', 'GitLab incoming webhook'), ('api_webhook', 'Generic API incoming webhook')], max_length=32, verbose_name='Integration type'), + ), + ] diff --git a/readthedocs/oauth/migrations/0009_add_missing_model_change_migrations.py b/readthedocs/oauth/migrations/0009_add_missing_model_change_migrations.py new file mode 100644 index 00000000000..015c233ac20 --- /dev/null +++ b/readthedocs/oauth/migrations/0009_add_missing_model_change_migrations.py @@ -0,0 +1,31 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.16 on 2018-10-31 11:25 +from __future__ import unicode_literals + +import django.core.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('oauth', '0008_add-project-relation'), + ] + + operations = [ + migrations.AlterField( + model_name='remoterepository', + name='clone_url', + field=models.URLField(blank=True, max_length=512, validators=[django.core.validators.URLValidator(schemes=['http', 'https', 'ssh', 'git', 'svn'])], verbose_name='Repository clone URL'), + ), + migrations.AlterField( + model_name='remoterepository', + name='ssh_url', + field=models.URLField(blank=True, max_length=512, validators=[django.core.validators.URLValidator(schemes=['ssh'])], verbose_name='SSH URL'), + ), + migrations.AlterField( + model_name='remoterepository', + name='vcs', + field=models.CharField(blank=True, choices=[('git', 'Git'), ('svn', 'Subversion'), ('hg', 'Mercurial'), ('bzr', 'Bazaar')], max_length=200, verbose_name='vcs'), + ), + ] diff --git a/readthedocs/redirects/migrations/0002_add_missing_model_change_migrations.py b/readthedocs/redirects/migrations/0002_add_missing_model_change_migrations.py new file mode 100644 index 00000000000..a837e6fb146 --- /dev/null +++ b/readthedocs/redirects/migrations/0002_add_missing_model_change_migrations.py @@ -0,0 +1,25 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.16 on 2018-10-31 11:25 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('redirects', '0001_initial'), + ] + + operations = [ + migrations.AlterField( + model_name='redirect', + name='redirect_type', + field=models.CharField(choices=[('prefix', 'Prefix Redirect'), ('page', 'Page Redirect'), ('exact', 'Exact Redirect'), ('sphinx_html', 'Sphinx HTMLDir -> HTML'), ('sphinx_htmldir', 'Sphinx HTML -> HTMLDir')], help_text='The type of redirect you wish to use.', max_length=255, verbose_name='Redirect Type'), + ), + migrations.AlterField( + model_name='redirect', + name='to_url', + field=models.CharField(blank=True, db_index=True, help_text='Absolute or relative URL. Example: /tutorial/install.html', max_length=255, verbose_name='To URL'), + ), + ] diff --git a/tox.ini b/tox.ini index cc48c77cb94..c1c88f10fc1 100644 --- a/tox.ini +++ b/tox.ini @@ -28,6 +28,12 @@ changedir = {toxinidir}/docs commands = sphinx-build -b html -d {envtmpdir}/doctrees . {envtmpdir}/html +[testenv:migrations] +description = check for missing migrations +changedir = {toxinidir} +commands = + ./manage.py makemigrations --check --dry-run + [testenv:docs-lint] description = run linter (rstcheck) to ensure there aren't errors on our docs deps = -r{toxinidir}/requirements/docs-lint.txt