diff --git a/django_migration_linter/migration_linter.py b/django_migration_linter/migration_linter.py index 38de743..78e6ca7 100644 --- a/django_migration_linter/migration_linter.py +++ b/django_migration_linter/migration_linter.py @@ -13,161 +13,169 @@ # limitations under the License. from __future__ import print_function -import argparse import logging as log import os +from io import StringIO import re from subprocess import Popen, PIPE import sys +from . import utils +from .sql_analyser import analyse_sql_statements -def has_default(sql, **kwargs): - if re.search('SET DEFAULT', sql) and kwargs['errors']: - err = next(err - for err in kwargs['errors'] - if err['code'] == 'NOT_NULL') - if err: - log.info( - ('Found a NOT_NULL error in migration, ' - 'but it has a default value added: {}').format(err)) - kwargs['errors'].remove(err) - - return False # Never fails - - -def clean_bytes_to_str(byte_input): - return byte_input.decode('utf-8').strip() - - -class MigrationLinter: +class MigrationLinter(object): MIGRATION_FOLDER_NAME = 'migrations' - migration_tests = ( - { - 'code': 'NOT_NULL', - 'fn': lambda sql, **kw: re.search('NOT NULL', sql) and - not re.search('CREATE TABLE', sql), - 'err_msg': 'NOT NULL constraint on columns' - }, { - 'code': 'DROP_COLUMN', - 'fn': lambda sql, **kw: re.search('DROP COLUMN', sql), - 'err_msg': 'DROPPING columns' - }, { - 'code': 'RENAME_COLUMN', - 'fn': lambda sql, **kw: re.search('ALTER TABLE .* CHANGE', sql) or - re.search('ALTER TABLE .* RENAME COLUMN', sql), - 'err_msg': 'RENAMING columns' - }, { - 'code': 'RENAME_TABLE', - 'fn': lambda sql, **kw: re.search('RENAME TABLE', sql) or - re.search('ALTER TABLE .* RENAME TO', sql), - 'err_msg': 'RENAMING tables' - }, { - 'code': '', - 'fn': has_default, - 'err_msg': '' - } - ) + def __init__(self, project_path, **kwargs): + # Verify correctness + if not utils.is_directory(project_path): + raise ValueError('The given path {0} does not seem to be a directory.'.format(project_path)) + if not utils.is_django_project(project_path): + raise ValueError('The given path {0} does not seem to be a django project.'.format(project_path)) - def __init__(self, django_folder, commit_id=None, **kwargs): - self.location = django_folder - self.commit_id = commit_id + # Store parameters and options + self.django_path = project_path self.ignore_name_contains = kwargs.get('ignore_name_contains', None) self.ignore_name = kwargs.get('ignore_name', None) or tuple() self.include_apps = kwargs.get('include_apps', None) self.exclude_apps = kwargs.get('exclude_apps', None) self.database = kwargs.get('database', None) or 'default' - self.changed_migration_files = [] - self._gather_migrations() + # Initialise counters + self.nb_valid = 0 + self.nb_ignored = 0 + self.nb_erroneous = 0 + self.nb_total = 0 - def _gather_migrations(self): - # Find (one of) the initial commits - if not self.commit_id: - git_init_cmd = 'cd {0} && git rev-list HEAD | tail -n 1'.format( - self.location) - process = Popen(git_init_cmd, shell=True, stdout=PIPE, stderr=PIPE) - for line in map(clean_bytes_to_str, process.stdout.readlines()): - self.commit_id = line - break - process.wait() - log.info('Operating until git identifier {0}'.format(self.commit_id)) + def lint_migration(self, app_name, migration_name): + print('({0}, {1})... '.format(app_name, migration_name), end='') + self.nb_total += 1 + if self.should_ignore_migration(app_name, migration_name): + print('IGNORE') + self.nb_ignore += 1 + return + + sql_statements = self.get_sql( + app_name, migration_name) + analysis_result = analyse_sql_statements( + sql_statements) + errors = analysis_result['errors'] + if not errors: + print('OK') + self.nb_valid += 1 + return + + # Print errors + print('ERR') + self.nb_erroneous += 1 + for err in errors: + error_str = '\t{0}'.format(err['err_msg']) + if err['table']: + error_str += ' (table: {0}'.format(err['table']) + if err['column']: + error_str += ', column: {0}'.format( + err['column']) + error_str += ')' + print(error_str) + + def lint_all_migrations(self, git_commit_id=None): + # Collect migrations + if git_commit_id: + if not utils.is_git_project(self.django_path): + raise ValueError('The given project {0} does not seem to be versioned by git.'.format(self.django_path)) + migrations = self._gather_migrations_git(git_commit_id) + else: + migrations = self._gather_all_migrations() + + # Lint those migrations + for m in migrations: + self.lint_migration(*m) + + def print_summary(self): + print('*** Summary:') + print(('Valid migrations: {1}/{0} - ' + 'erroneous migrations: {2}/{0} - ' + 'ignored migrations: {3}/{0}').format( + self.nb_total, + self.nb_valid, + self.nb_erroneous, + self.nb_ignore)) + + @property + def has_errors(self): + return self.nb_erroneous > 0 + + def get_sql(self, app_name, migration_name): + """ It would be much faster to call the + command directly from the code using + call_command(), but requires the code + to setup django (by calling django.setup()) + and set the DJANGO_SETTINGS_MODULE. + However, django is global and doesn't allow + multiple linter instances to exist at the same time. + (because they would all just lint the same django project) + Even if calling a shell is slow and ugly, for now, + it allows to seperate the instances correctly. + """ + git_diff_command = ( + 'cd {0} && ' + 'python manage.py sqlmigrate {1} {2} ' + '--database {3}').format( + self.django_path, app_name, migration_name, self.database) + log.info('Executing {0}'.format(git_diff_command)) + sqlmigrate_process = Popen( + git_diff_command, shell=True, stdout=PIPE, stderr=PIPE) + + sql_statements = [] + for line in map( + utils.clean_bytes_to_str, sqlmigrate_process.stdout.readlines()): + sql_statements.append(line) + sqlmigrate_process.wait() + if sqlmigrate_process.returncode != 0: + raise RuntimeError('sqlmigrate command failed') + log.info('Found {0} sql migration lines'.format(len(sql_statements))) + return sql_statements + + def _gather_migrations_git(self, git_commit_id): + migrations = [] # Get changes since specified commit git_diff_command = 'cd {0} && git diff --name-only {1}'.format( - self.location, self.commit_id) + self.django_path, git_commit_id) log.info('Executing {0}'.format(git_diff_command)) diff_process = Popen( git_diff_command, shell=True, stdout=PIPE, stderr=PIPE) - for line in map(clean_bytes_to_str, diff_process.stdout.readlines()): + for line in map(utils.clean_bytes_to_str, diff_process.stdout.readlines()): # Only gather lines that include migrations if re.search( '\/{0}\/.*\.py'.format(self.MIGRATION_FOLDER_NAME), line) and \ '__init__' not in line: - self.changed_migration_files.append(line) + app_name, migration_name = self._split_migration_path(line) + migrations.append((app_name, migration_name)) diff_process.wait() + if diff_process.returncode != 0: output = [] for line in map( - clean_bytes_to_str, diff_process.stderr.readlines()): + utils.clean_bytes_to_str, diff_process.stderr.readlines()): output.append(line) log.info("Error while git diff command:\n{}".format( "".join(output))) raise Exception('Error while executing git diff command') + return migrations - def lint_migrations(self): - nb_valid = 0 - nb_erroneous = 0 - nb_ignore = 0 - for migration in self.changed_migration_files: - app_name, migration_name = self._split_migration_path(migration) - print('{0}... '.format(migration), end='') - if self.should_ignore_migration(app_name, migration_name): - print('IGNORE') - nb_ignore += 1 - else: - sql_statements = self.django_sqlmigrate( - app_name, migration_name) - errors = [] - for statement in sql_statements: - is_valid, err = \ - self._test_sql_statement_for_backward_incompatibility( - statement, errors) - if not is_valid: - errors.append(err) - if not errors: - print('OK') - nb_valid += 1 - else: - print('ERR') - nb_erroneous += 1 - for err in errors: - error_str = '\t{0}'.format(err['err_msg']) - if err['table']: - error_str += ' (table: {0}'.format(err['table']) - if err['column']: - error_str += ', column: {0}'.format( - err['column']) - error_str += ')' - print(error_str) - print('*** Summary:') - print(('Valid migrations: {0}/{1} - ' - 'erroneous migrations: {2}/{1} - ' - 'ignored migrations: {3}/{1}').format( - nb_valid, - len(self.changed_migration_files), - nb_erroneous, - nb_ignore)) - return nb_erroneous > 0 - - @classmethod - def _split_migration_path(cls, migration_path): - decomposed_path = split_path(migration_path) - for i, p in enumerate(decomposed_path): - if p == cls.MIGRATION_FOLDER_NAME: - return (decomposed_path[i-1], - os.path.splitext(decomposed_path[i+1])[0]) + def _gather_all_migrations(self): + migrations = [] + for root, dirs, files in os.walk(self.django_path): + for file_name in files: + if os.path.basename(root) == self.MIGRATION_FOLDER_NAME and \ + file_name.endswith('.py') and \ + file_name != '__init__.py': + full_migration_path = os.path.join(root, file_name) + app_name, migration_name = self._split_migration_path(full_migration_path) + migrations.append((app_name, migration_name)) + return migrations def should_ignore_migration(self, app_name, migration_name): return (self.include_apps and @@ -178,73 +186,17 @@ class MigrationLinter: self.ignore_name_contains in migration_name)\ or (migration_name in self.ignore_name) - def django_sqlmigrate(self, app_name, migration_name): - git_diff_command = ( - 'cd {0} && ' - 'python manage.py sqlmigrate {1} {2} ' - '--database {3}').format( - self.location, app_name, migration_name, self.database) - log.info('Executing {0}'.format(git_diff_command)) - sqlmigrate_process = Popen( - git_diff_command, shell=True, stdout=PIPE, stderr=PIPE) - sql_statements = [] - for line in map( - clean_bytes_to_str, sqlmigrate_process.stdout.readlines()): - if not line.startswith('--'): # Ignore comments - sql_statements.append(line) - sqlmigrate_process.wait() - if sqlmigrate_process.returncode != 0: - raise RuntimeError('sqlmigrate command failed') - log.info('Found {0} sql migration lines'.format(len(sql_statements))) - return sql_statements - - def _test_sql_statement_for_backward_incompatibility( - self, sql_statement, errors): - for test in self.migration_tests: - if test['fn'](sql_statement, errors=errors): - log.info('Testing {0} -- ERROR'.format(sql_statement)) - table_search = re.search( - 'TABLE `([^`]*)`', sql_statement, re.IGNORECASE) - col_search = re.search( - 'COLUMN `([^`]*)`', sql_statement, re.IGNORECASE) - err = { - 'err_msg': test['err_msg'], - 'code': test['code'], - 'table': table_search.group(1) if table_search else None, - 'column': col_search.group(1) if col_search else None - } - return False, err - log.info('Testing {0} -- PASSED'.format(sql_statement)) - return True, None - - -def valid_folder(folder): - """Verify folder exists, - folder is a django project - and folder is git versioned - """ - if not os.path.isdir(folder): - print("The passed argument doesn't seem to be a folder.") - return False - django_manage_file = os.path.join(folder, 'manage.py') - if not os.path.isfile(django_manage_file): - print(("The passed folder doesn't seem to be a " - "django project (no manage.py found).")) - return False - git_folder = os.path.join(folder, '.git') - if not os.path.isdir(git_folder): - print(("The passed folder doesn't seem to be " - "versioned by git (no .git/ folder found).")) - return False - return True - - -def split_path(path): - a, b = os.path.split(path) - return (split_path(a) if len(a) > 0 else []) + [b] + @classmethod + def _split_migration_path(cls, migration_path): + decomposed_path = utils.split_path(migration_path) + for i, p in enumerate(decomposed_path): + if p == cls.MIGRATION_FOLDER_NAME: + return (decomposed_path[i-1], + os.path.splitext(decomposed_path[i+1])[0]) def _main(): + import argparse parser = argparse.ArgumentParser( description='Detect backward incompatible django migrations.') parser.add_argument( @@ -302,19 +254,18 @@ def _main(): log.basicConfig(format='%(message)s') folder_name = args.django_folder[0] - if valid_folder(folder_name): - linter = MigrationLinter( - folder_name, - args.commit_id, - ignore_name_contains=args.ignore_name_contains, - ignore_name=args.ignore_name, - include_apps=args.include_apps, - exclude_apps=args.exclude_apps, - database=args.database) - has_errors = linter.lint_migrations() - if has_errors: - sys.exit(1) - else: + # Create and use linter + linter = MigrationLinter( + folder_name, + ignore_name_contains=args.ignore_name_contains, + ignore_name=args.ignore_name, + include_apps=args.include_apps, + exclude_apps=args.exclude_apps, + database=args.database) + linter.lint_all_migrations( + git_commit_id=args.commit_id) + linter.print_summary() + if linter.has_errors: sys.exit(1) diff --git a/django_migration_linter/sql_analyser.py b/django_migration_linter/sql_analyser.py new file mode 100644 index 0000000..121a767 --- /dev/null +++ b/django_migration_linter/sql_analyser.py @@ -0,0 +1,82 @@ +# Copyright 2017 3YOURMIND GmbH + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import re +import logging as log + + +def has_default(sql, **kwargs): + if re.search('SET DEFAULT', sql) and kwargs['errors']: + err = next(err + for err in kwargs['errors'] + if err['code'] == 'NOT_NULL') + if err: + log.info( + ('Found a NOT_NULL error in migration, ' + 'but it has a default value added: {}').format(err)) + kwargs['errors'].remove(err) + + return False # Never fails + + +migration_tests = ( + { + 'code': 'NOT_NULL', + 'fn': lambda sql, **kw: re.search('NOT NULL', sql) and + not re.search('CREATE TABLE', sql), + 'err_msg': 'NOT NULL constraint on columns' + }, { + 'code': 'DROP_COLUMN', + 'fn': lambda sql, **kw: re.search('DROP COLUMN', sql), + 'err_msg': 'DROPPING columns' + }, { + 'code': 'RENAME_COLUMN', + 'fn': lambda sql, **kw: re.search('ALTER TABLE .* CHANGE', sql) or + re.search('ALTER TABLE .* RENAME COLUMN', sql), + 'err_msg': 'RENAMING columns' + }, { + 'code': 'RENAME_TABLE', + 'fn': lambda sql, **kw: re.search('RENAME TABLE', sql) or + re.search('ALTER TABLE .* RENAME TO', sql), + 'err_msg': 'RENAMING tables' + }, { + 'code': '', + 'fn': has_default, + 'err_msg': '' + } +) + + +def analyse_sql_statements(sql_statements): + errors = [] + for statement in sql_statements: + for test in migration_tests: + if test['fn'](statement, errors=errors): + log.info('Testing {0} -- ERROR'.format(statement)) + table_search = re.search( + 'TABLE `([^`]*)`', statement, re.IGNORECASE) + col_search = re.search( + 'COLUMN `([^`]*)`', statement, re.IGNORECASE) + err = { + 'err_msg': test['err_msg'], + 'code': test['code'], + 'table': table_search.group(1) if table_search else None, + 'column': col_search.group(1) if col_search else None + } + errors.append(err) + else: + log.info('Testing {0} -- PASSED'.format(statement)) + return { + 'errors': errors, + } diff --git a/django_migration_linter/utils.py b/django_migration_linter/utils.py new file mode 100644 index 0000000..c27aadd --- /dev/null +++ b/django_migration_linter/utils.py @@ -0,0 +1,54 @@ +# Copyright 2017 3YOURMIND GmbH + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +from __future__ import print_function +import os +import re + + +def is_django_project(path): + django_manage_file = os.path.join(path, 'manage.py') + return os.path.isfile(django_manage_file) + + +def is_git_project(path): + git_directory = os.path.join(path, '.git') + return os.path.isdir(git_directory) + + +def is_directory(path): + return os.path.isdir(path) + + +def print_stderr(*args, **kwargs): + print(*args, file=sys.stderr, **kwargs) + + +def find_project_settings_module(path): + """Explore path recursively to the first settings.py file + and translate the name to package notation 'mysite.settings' + """ + for root, dirs, files in os.walk(path): + for file_name in files: + if file_name == 'settings.py': + return os.path.join(root.replace(path, ''), file_name).replace('/', '.').rstrip('.py') + + +def split_path(path): + a, b = os.path.split(path) + return (split_path(a) if (len(a) > 0 and a != '/') else []) + [b] + + +def clean_bytes_to_str(byte_input): + return byte_input.decode('utf-8').strip() diff --git a/tests/fixtures.py b/tests/fixtures.py index e3748c6..0bd647b 100644 --- a/tests/fixtures.py +++ b/tests/fixtures.py @@ -34,6 +34,8 @@ ADD_NOT_NULL_COLUMN_FOLLOWED_BY_DEFAULT_PROJECT = os.path.join( _FIXTURES_FOLDER, 'test_project_add_not_null_column_followed_by_default/') MULTI_COMMIT_PROJECT = os.path.join( _FIXTURES_FOLDER, 'test_project_multi_commit/') +CORRECT_PROJECT = os.path.join( + _FIXTURES_FOLDER, 'test_correct_project/') NOT_DJANGO_GIT_PROJECT = os.path.join( _FIXTURES_FOLDER, 'test_git_project/') @@ -42,12 +44,6 @@ NOT_GIT_DJANGO_PROJECT = os.path.join( ALL_GIT_PROJECTS = ( NOT_DJANGO_GIT_PROJECT, - ADD_NOT_NULL_COLUMN_PROJECT, - CREATE_TABLE_WITH_NOT_NULL_COLUMN_PROJECT, - DROP_COLUMN_PROJECT, - RENAME_COLUMN_PROJECT, - RENAME_TABLE_PROJECT, - ADD_NOT_NULL_COLUMN_FOLLOWED_BY_DEFAULT_PROJECT, MULTI_COMMIT_PROJECT ) diff --git a/tests/functional/test_cmd_line_call.py b/tests/functional/test_cmd_line_call.py new file mode 100644 index 0000000..c102528 --- /dev/null +++ b/tests/functional/test_cmd_line_call.py @@ -0,0 +1,4 @@ +import unittest + +class CallLinterFromCommandLineTest(unittest.TestCase): + pass diff --git a/tests/functional/test_migration_linter.py b/tests/functional/test_migration_linter.py index da5c7aa..192372f 100644 --- a/tests/functional/test_migration_linter.py +++ b/tests/functional/test_migration_linter.py @@ -66,19 +66,19 @@ class BackwardcompatibilityDetectionTest(unittest.TestCase): fixtures.prepare_git_project(test_project_path) self._test_linter_finds_no_errors( test_project_path, - commit_id='44330921696018f8f1480df897b38310549982cb') + commit_id='1021d98b5943db56122c1f848f371ddc38788d0f') - #def test_specify_git_hash_by_tag(self): - # test_project_path = fixtures.MULTI_COMMIT_PROJECT - # fixtures.prepare_git_project(test_project_path) - # self._test_linter_finds_no_errors(test_project_path, commit_id='tag1') + def test_specify_git_hash_by_tag(self): + test_project_path = fixtures.MULTI_COMMIT_PROJECT + fixtures.prepare_git_project(test_project_path) + self._test_linter_finds_no_errors(test_project_path, commit_id='tag1') def _test_linter_finds_errors(self, path, commit_id=None): - linter = MigrationLinter(path, commit_id=commit_id) - has_errors = linter.lint_migrations() - self.assertTrue(has_errors) + linter = MigrationLinter(path) + linter.lint_all_migrations(git_commit_id=commit_id) + self.assertTrue(linter.has_errors) def _test_linter_finds_no_errors(self, path, commit_id=None): - linter = MigrationLinter(path, commit_id=commit_id) - has_errors = linter.lint_migrations() - self.assertFalse(has_errors) + linter = MigrationLinter(path) + linter.lint_all_migrations(git_commit_id=commit_id) + self.assertFalse(linter.has_errors) diff --git a/tests/functional/test_multiple_calls.py b/tests/functional/test_multiple_calls.py new file mode 100644 index 0000000..77bf3e1 --- /dev/null +++ b/tests/functional/test_multiple_calls.py @@ -0,0 +1,23 @@ +import unittest + +from django_migration_linter import MigrationLinter +from tests import fixtures + +class TestMultipleLinters(unittest.TestCase): + def test_multiple_linters(self): + l1 = MigrationLinter(fixtures.ADD_NOT_NULL_COLUMN_PROJECT) + l2 = MigrationLinter(fixtures.RENAME_COLUMN_PROJECT) + l3 = MigrationLinter(fixtures.CORRECT_PROJECT) + + l1.lint_migration('test_app', '0002') + l2.lint_migration('test_app', '0002') + l3.lint_migration('test_app1', '0001') + l3.lint_migration('test_app1', '0002') + + self.assertTrue(l1.has_errors) + self.assertTrue(l2.has_errors) + self.assertFalse(l3.has_errors) + + self.assertEqual(l1.nb_total, 1) + self.assertEqual(l2.nb_total, 1) + self.assertEqual(l3.nb_total, 2) diff --git a/tests/test_project_fixtures/test_correct_project/.gitignore b/tests/test_project_fixtures/test_correct_project/.gitignore new file mode 100644 index 0000000..63973d0 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/.gitignore @@ -0,0 +1,3 @@ +*.pyc +__pycache__/ +*sqlite3 diff --git a/tests/test_project_fixtures/test_correct_project/manage.py b/tests/test_project_fixtures/test_correct_project/manage.py new file mode 100644 index 0000000..3390cc6 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/manage.py @@ -0,0 +1,22 @@ +#!/usr/bin/env python +import os +import sys + +if __name__ == "__main__": + os.environ.setdefault("DJANGO_SETTINGS_MODULE", "test_project.settings") + try: + from django.core.management import execute_from_command_line + except ImportError: + # The above import may fail for some other reason. Ensure that the + # issue is really that Django is missing to avoid masking other + # exceptions on Python 2. + try: + import django + except ImportError: + raise ImportError( + "Couldn't import Django. Are you sure it's installed and " + "available on your PYTHONPATH environment variable? Did you " + "forget to activate a virtual environment?" + ) + raise + execute_from_command_line(sys.argv) diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/__init__.py b/tests/test_project_fixtures/test_correct_project/test_app1/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/admin.py b/tests/test_project_fixtures/test_correct_project/test_app1/admin.py new file mode 100644 index 0000000..8c38f3f --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/apps.py b/tests/test_project_fixtures/test_correct_project/test_app1/apps.py new file mode 100644 index 0000000..1dc36fd --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/apps.py @@ -0,0 +1,5 @@ +from django.apps import AppConfig + + +class TestApp1Config(AppConfig): + name = 'test_app1' diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0001_initial.py b/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0001_initial.py new file mode 100644 index 0000000..681a3fc --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0001_initial.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.7 on 2017-11-27 15:49 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='A', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('null_field', models.IntegerField(null=True)), + ], + ), + ] diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0002_a_new_null_field.py b/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0002_a_new_null_field.py new file mode 100644 index 0000000..010e2b1 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/migrations/0002_a_new_null_field.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.7 on 2017-11-27 15:49 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('test_app1', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='a', + name='new_null_field', + field=models.IntegerField(null=True), + ), + ] diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/migrations/__init__.py b/tests/test_project_fixtures/test_correct_project/test_app1/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/models.py b/tests/test_project_fixtures/test_correct_project/test_app1/models.py new file mode 100644 index 0000000..f13a3bf --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/models.py @@ -0,0 +1,5 @@ +from django.db import models + +class A(models.Model): + null_field = models.IntegerField(null=True) + new_null_field = models.IntegerField(null=True) diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/tests.py b/tests/test_project_fixtures/test_correct_project/test_app1/tests.py new file mode 100644 index 0000000..7ce503c --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/tests/test_project_fixtures/test_correct_project/test_app1/views.py b/tests/test_project_fixtures/test_correct_project/test_app1/views.py new file mode 100644 index 0000000..91ea44a --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app1/views.py @@ -0,0 +1,3 @@ +from django.shortcuts import render + +# Create your views here. diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/__init__.py b/tests/test_project_fixtures/test_correct_project/test_app2/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/admin.py b/tests/test_project_fixtures/test_correct_project/test_app2/admin.py new file mode 100644 index 0000000..8c38f3f --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/apps.py b/tests/test_project_fixtures/test_correct_project/test_app2/apps.py new file mode 100644 index 0000000..13aa724 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/apps.py @@ -0,0 +1,5 @@ +from django.apps import AppConfig + + +class TestApp2Config(AppConfig): + name = 'test_app2' diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/migrations/0001_foo.py b/tests/test_project_fixtures/test_correct_project/test_app2/migrations/0001_foo.py new file mode 100644 index 0000000..4f7ae75 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/migrations/0001_foo.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.7 on 2017-11-29 21:08 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='B', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('null_field', models.IntegerField(null=True)), + ], + ), + ] diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/migrations/__init__.py b/tests/test_project_fixtures/test_correct_project/test_app2/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/models.py b/tests/test_project_fixtures/test_correct_project/test_app2/models.py new file mode 100644 index 0000000..2633c55 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/models.py @@ -0,0 +1,4 @@ +from django.db import models + +class B(models.Model): + null_field = models.IntegerField(null=True) diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/tests.py b/tests/test_project_fixtures/test_correct_project/test_app2/tests.py new file mode 100644 index 0000000..7ce503c --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/tests/test_project_fixtures/test_correct_project/test_app2/views.py b/tests/test_project_fixtures/test_correct_project/test_app2/views.py new file mode 100644 index 0000000..91ea44a --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_app2/views.py @@ -0,0 +1,3 @@ +from django.shortcuts import render + +# Create your views here. diff --git a/tests/test_project_fixtures/test_correct_project/test_project/__init__.py b/tests/test_project_fixtures/test_correct_project/test_project/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_project_fixtures/test_correct_project/test_project/settings.py b/tests/test_project_fixtures/test_correct_project/test_project/settings.py new file mode 100644 index 0000000..f0642cc --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_project/settings.py @@ -0,0 +1,121 @@ +""" +Django settings for test_project project. + +Generated by 'django-admin startproject' using Django 1.11.6. + +For more information on this file, see +https://docs.djangoproject.com/en/1.11/topics/settings/ + +For the full list of settings and their values, see +https://docs.djangoproject.com/en/1.11/ref/settings/ +""" + +import os + +# Build paths inside the project like this: os.path.join(BASE_DIR, ...) +BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) + + +# Quick-start development settings - unsuitable for production +# See https://docs.djangoproject.com/en/1.11/howto/deployment/checklist/ + +# SECURITY WARNING: keep the secret key used in production secret! +SECRET_KEY = 'gtb+mohs%gf0+#fr89vw7e&#edmv=q8!iv+n&j_soawk$tkj3^' + +# SECURITY WARNING: don't run with debug turned on in production! +DEBUG = True + +ALLOWED_HOSTS = [] + + +# Application definition + +INSTALLED_APPS = [ + 'django.contrib.admin', + 'django.contrib.auth', + 'django.contrib.contenttypes', + 'django.contrib.sessions', + 'django.contrib.messages', + 'django.contrib.staticfiles', + 'test_app1', + 'test_app2' +] + +MIDDLEWARE = [ + 'django.middleware.security.SecurityMiddleware', + 'django.contrib.sessions.middleware.SessionMiddleware', + 'django.middleware.common.CommonMiddleware', + 'django.middleware.csrf.CsrfViewMiddleware', + 'django.contrib.auth.middleware.AuthenticationMiddleware', + 'django.contrib.messages.middleware.MessageMiddleware', + 'django.middleware.clickjacking.XFrameOptionsMiddleware', +] + +ROOT_URLCONF = 'test_project.urls' + +TEMPLATES = [ + { + 'BACKEND': 'django.template.backends.django.DjangoTemplates', + 'DIRS': [], + 'APP_DIRS': True, + 'OPTIONS': { + 'context_processors': [ + 'django.template.context_processors.debug', + 'django.template.context_processors.request', + 'django.contrib.auth.context_processors.auth', + 'django.contrib.messages.context_processors.messages', + ], + }, + }, +] + +WSGI_APPLICATION = 'test_project.wsgi.application' + + +# Database +# https://docs.djangoproject.com/en/1.11/ref/settings/#databases + +DATABASES = { + 'default': { + 'ENGINE': 'django_fake_database_backends.backends.mysql' + } +} + + +# Password validation +# https://docs.djangoproject.com/en/1.11/ref/settings/#auth-password-validators + +AUTH_PASSWORD_VALIDATORS = [ + { + 'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator', + }, + { + 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator', + }, +] + + +# Internationalization +# https://docs.djangoproject.com/en/1.11/topics/i18n/ + +LANGUAGE_CODE = 'en-us' + +TIME_ZONE = 'UTC' + +USE_I18N = True + +USE_L10N = True + +USE_TZ = True + + +# Static files (CSS, JavaScript, Images) +# https://docs.djangoproject.com/en/1.11/howto/static-files/ + +STATIC_URL = '/static/' diff --git a/tests/test_project_fixtures/test_correct_project/test_project/urls.py b/tests/test_project_fixtures/test_correct_project/test_project/urls.py new file mode 100644 index 0000000..735de5d --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_project/urls.py @@ -0,0 +1,21 @@ +"""linter_test_project URL Configuration + +The `urlpatterns` list routes URLs to views. For more information please see: + https://docs.djangoproject.com/en/1.11/topics/http/urls/ +Examples: +Function views + 1. Add an import: from my_app import views + 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') +Class-based views + 1. Add an import: from other_app.views import Home + 2. Add a URL to urlpatterns: url(r'^$', Home.as_view(), name='home') +Including another URLconf + 1. Import the include() function: from django.conf.urls import url, include + 2. Add a URL to urlpatterns: url(r'^blog/', include('blog.urls')) +""" +from django.conf.urls import url +from django.contrib import admin + +urlpatterns = [ + url(r'^admin/', admin.site.urls), +] diff --git a/tests/test_project_fixtures/test_correct_project/test_project/wsgi.py b/tests/test_project_fixtures/test_correct_project/test_project/wsgi.py new file mode 100644 index 0000000..aa66ac1 --- /dev/null +++ b/tests/test_project_fixtures/test_correct_project/test_project/wsgi.py @@ -0,0 +1,16 @@ +""" +WSGI config for linter_test_project project. + +It exposes the WSGI callable as a module-level variable named ``application``. + +For more information on this file, see +https://docs.djangoproject.com/en/1.11/howto/deployment/wsgi/ +""" + +import os + +from django.core.wsgi import get_wsgi_application + +os.environ.setdefault("DJANGO_SETTINGS_MODULE", "test_project.settings") + +application = get_wsgi_application() diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_add_not_null_column/git/COMMIT_EDITMSG deleted file mode 100644 index c347860..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/COMMIT_EDITMSG +++ /dev/null @@ -1,22 +0,0 @@ -All files - -# Veuillez saisir le message de validation pour vos modifications. Les lignes -# commençant par '#' seront ignorées, et un message vide abandonne la validation. -# Sur la branche master -# Modifications qui seront validées : -# nouveau fichier: .gitignore -# nouveau fichier: manage.py -# nouveau fichier: test_app/__init__.py -# nouveau fichier: test_app/admin.py -# nouveau fichier: test_app/apps.py -# nouveau fichier: test_app/migrations/0001_create_table.py -# nouveau fichier: test_app/migrations/0002_add_new_not_null_field.py -# nouveau fichier: test_app/migrations/__init__.py -# nouveau fichier: test_app/models.py -# nouveau fichier: test_app/tests.py -# nouveau fichier: test_app/views.py -# nouveau fichier: test_project_add_not_null_column/__init__.py -# nouveau fichier: test_project_add_not_null_column/settings.py -# nouveau fichier: test_project_add_not_null_column/urls.py -# nouveau fichier: test_project_add_not_null_column/wsgi.py -# diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/HEAD b/tests/test_project_fixtures/test_project_add_not_null_column/git/HEAD deleted file mode 100644 index cb089cd..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/HEAD +++ /dev/null @@ -1 +0,0 @@ -ref: refs/heads/master diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/config b/tests/test_project_fixtures/test_project_add_not_null_column/git/config deleted file mode 100644 index eeb8dd7..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/config +++ /dev/null @@ -1,5 +0,0 @@ -[core] - repositoryformatversion = 0 - filemode = false - bare = false - logallrefupdates = true diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/description b/tests/test_project_fixtures/test_project_add_not_null_column/git/description deleted file mode 100644 index 498b267..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/description +++ /dev/null @@ -1 +0,0 @@ -Unnamed repository; edit this file 'description' to name the repository. diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/index b/tests/test_project_fixtures/test_project_add_not_null_column/git/index deleted file mode 100644 index 1a18263..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/index and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/info/exclude b/tests/test_project_fixtures/test_project_add_not_null_column/git/info/exclude deleted file mode 100644 index a5196d1..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/info/exclude +++ /dev/null @@ -1,6 +0,0 @@ -# git ls-files --others --exclude-from=.git/info/exclude -# Lines that start with '#' are comments. -# For a project mostly in C, the following would be a good set of -# exclude patterns (uncomment them if you want to use them): -# *.[oa] -# *~ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/HEAD b/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/HEAD deleted file mode 100644 index c52e8aa..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/HEAD +++ /dev/null @@ -1,3 +0,0 @@ -0000000000000000000000000000000000000000 13850658e796761657478d38eacd426e208b05b0 David-Wobrock 1509046620 +0200 commit (initial): Init -13850658e796761657478d38eacd426e208b05b0 0c78bfd0462272a51e3515731a6e6776bea72f72 David-Wobrock 1509046634 +0200 commit: All files -0c78bfd0462272a51e3515731a6e6776bea72f72 13ddff99f80afca39dc64eaa65928244584a88d3 David-Wobrock 1509046854 +0200 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/refs/heads/master deleted file mode 100644 index c52e8aa..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/logs/refs/heads/master +++ /dev/null @@ -1,3 +0,0 @@ -0000000000000000000000000000000000000000 13850658e796761657478d38eacd426e208b05b0 David-Wobrock 1509046620 +0200 commit (initial): Init -13850658e796761657478d38eacd426e208b05b0 0c78bfd0462272a51e3515731a6e6776bea72f72 David-Wobrock 1509046634 +0200 commit: All files -0c78bfd0462272a51e3515731a6e6776bea72f72 13ddff99f80afca39dc64eaa65928244584a88d3 David-Wobrock 1509046854 +0200 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac deleted file mode 100644 index 4d7d160..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac +++ /dev/null @@ -1,3 +0,0 @@ -x]PËjÃ0ìÙ_±�ƒ�;Ôm øRrÈ­·„m­�ZY2zÒ¯¯dåY„˜™�™UÃee™?Ì }L¡•”‰~Öté«G¢¼£@U¤ÐaóU‹^B‘Eö RÀ2/^Ò"O—%O«¼Œ:% ¤³Æ*$Ø0JeÀ -æÌ‘pfœ×QÒÉ/£ÍY7°Þ…1)ô7à•QËk­a¦’«(»€óU�;L0Ãj|(‹£8¢ (Z†ÚŸ“ð89úí|à…ñ67o -Ýú{_&™&=ï�¨¬âu¼¸C;†œê*„a¸“˜Ñø¼U¶¶Fn½4©Ý‹´S­|錊 µ:’o<ž�ÊmÅ~±Úºßs’T�ÔHB‰Ý&žÏï{øÐ$–s2UºFï„ÁUH÷‚)ãÿüájwr>Dqá£& \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/0c/78bfd0462272a51e3515731a6e6776bea72f72 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/0c/78bfd0462272a51e3515731a6e6776bea72f72 deleted file mode 100644 index 20be75f..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/0c/78bfd0462272a51e3515731a6e6776bea72f72 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/850658e796761657478d38eacd426e208b05b0 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/850658e796761657478d38eacd426e208b05b0 deleted file mode 100644 index eb88956..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/850658e796761657478d38eacd426e208b05b0 +++ /dev/null @@ -1,2 +0,0 @@ -x¥�Á -B!E[û³�óL…ˆmú‚ÖŽÎ+)Äê÷3ú„–ç¹'ÖRr‡ÙmW½‰€a§mŠdtdö Å^\"¯�[XÄx4*<ûµ68†WN›såVã vé‹Óû‡‡K ù>ÅZö0[‘FX£FTcá.\¨Ó#wõ"";ã \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/ddff99f80afca39dc64eaa65928244584a88d3 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/ddff99f80afca39dc64eaa65928244584a88d3 deleted file mode 100644 index 8ecddb5..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/13/ddff99f80afca39dc64eaa65928244584a88d3 +++ /dev/null @@ -1,3 +0,0 @@ -x•ŽA -Â0E]çÙ‹ešf&SQð®ÓɨÅÖH�z}+âü»÷�'yûb]C‹2©ZñÞÍKNñ-A”V# 0 - ×,€ ÄÜâ¤×bë†YCK�jÂ৆5JòŽÔw€˜ø(ç<Ù}|öiuÈÝ”åb×éƒÕë‹ÛÓû¡’tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/47b0f2a9845fa268ad4a19967c706e5d7be38b b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/47b0f2a9845fa268ad4a19967c706e5d7be38b deleted file mode 100644 index 621f4fc..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/47b0f2a9845fa268ad4a19967c706e5d7be38b and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/88/80cfa9557a6ce785b43fb300748310b7e995ed b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/88/80cfa9557a6ce785b43fb300748310b7e995ed deleted file mode 100644 index 688ed38..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/88/80cfa9557a6ce785b43fb300748310b7e995ed and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e deleted file mode 100644 index 13fc88e..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/bd/6e4d7737b3cb2f0ae260b05511342c3f6f1b45 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/bd/6e4d7737b3cb2f0ae260b05511342c3f6f1b45 deleted file mode 100644 index a2af518..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/bd/6e4d7737b3cb2f0ae260b05511342c3f6f1b45 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/c4/42222d2e5f0960ac9ea05c85c05818c070860c b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/c4/42222d2e5f0960ac9ea05c85c05818c070860c deleted file mode 100644 index eb8b496..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/c4/42222d2e5f0960ac9ea05c85c05818c070860c and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 deleted file mode 100644 index 61838b7..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa deleted file mode 100644 index 02f7652..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/f4/c75b2e69145f2c603b0a0851cc97757766e511 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/f4/c75b2e69145f2c603b0a0851cc97757766e511 deleted file mode 100644 index eedd426..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/f4/c75b2e69145f2c603b0a0851cc97757766e511 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 b/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 deleted file mode 100644 index a0339be..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/refs/heads/master b/tests/test_project_fixtures/test_project_add_not_null_column/git/refs/heads/master deleted file mode 100644 index ef760ea..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column/git/refs/heads/master +++ /dev/null @@ -1 +0,0 @@ -13ddff99f80afca39dc64eaa65928244584a88d3 diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/COMMIT_EDITMSG deleted file mode 100644 index e3faf61..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/COMMIT_EDITMSG +++ /dev/null @@ -1,23 +0,0 @@ -All files - -# Veuillez saisir le message de validation pour vos modifications. Les lignes -# commençant par '#' seront ignorées, et un message vide abandonne la validation. -# Sur la branche master -# Modifications qui seront validées : -# nouveau fichier: .gitignore -# nouveau fichier: manage.py -# nouveau fichier: test_app/__init__.py -# nouveau fichier: test_app/admin.py -# nouveau fichier: test_app/apps.py -# nouveau fichier: test_app/migrations/0001_create_table.py -# nouveau fichier: test_app/migrations/0002_add_new_not_null_field.py -# nouveau fichier: test_app/migrations/__init__.py -# nouveau fichier: test_app/migrations_utils.py -# nouveau fichier: test_app/models.py -# nouveau fichier: test_app/tests.py -# nouveau fichier: test_app/views.py -# nouveau fichier: test_project_add_not_null_column_followed_by_default/__init__.py -# nouveau fichier: test_project_add_not_null_column_followed_by_default/settings.py -# nouveau fichier: test_project_add_not_null_column_followed_by_default/urls.py -# nouveau fichier: test_project_add_not_null_column_followed_by_default/wsgi.py -# diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/HEAD b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/HEAD deleted file mode 100644 index cb089cd..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/HEAD +++ /dev/null @@ -1 +0,0 @@ -ref: refs/heads/master diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/config b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/config deleted file mode 100644 index eeb8dd7..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/config +++ /dev/null @@ -1,5 +0,0 @@ -[core] - repositoryformatversion = 0 - filemode = false - bare = false - logallrefupdates = true diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/description b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/description deleted file mode 100644 index 498b267..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/description +++ /dev/null @@ -1 +0,0 @@ -Unnamed repository; edit this file 'description' to name the repository. diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/index b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/index deleted file mode 100644 index 75cbd0c..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/index and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/info/exclude b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/info/exclude deleted file mode 100644 index a5196d1..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/info/exclude +++ /dev/null @@ -1,6 +0,0 @@ -# git ls-files --others --exclude-from=.git/info/exclude -# Lines that start with '#' are comments. -# For a project mostly in C, the following would be a good set of -# exclude patterns (uncomment them if you want to use them): -# *.[oa] -# *~ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/HEAD b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/HEAD deleted file mode 100644 index a0e2bfa..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/HEAD +++ /dev/null @@ -1,4 +0,0 @@ -0000000000000000000000000000000000000000 188d1e847da762e20ec43db374ffba8c5ee40581 David-Wobrock 1509048870 +0200 commit (initial): Init -188d1e847da762e20ec43db374ffba8c5ee40581 1ed2db048937886ab77c892d7ffa4bb3da6ae8a9 David-Wobrock 1509048882 +0200 commit: All files -1ed2db048937886ab77c892d7ffa4bb3da6ae8a9 4c2edb394b46664ac61f0b6fb29e57fe807ce21e David-Wobrock 1509049863 +0200 commit (amend): All files -4c2edb394b46664ac61f0b6fb29e57fe807ce21e 16fd55a08b9ad1af4282cafccf5c14adf1f2a1dc David-Wobrock 1509381987 +0100 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/refs/heads/master deleted file mode 100644 index a0e2bfa..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/logs/refs/heads/master +++ /dev/null @@ -1,4 +0,0 @@ -0000000000000000000000000000000000000000 188d1e847da762e20ec43db374ffba8c5ee40581 David-Wobrock 1509048870 +0200 commit (initial): Init -188d1e847da762e20ec43db374ffba8c5ee40581 1ed2db048937886ab77c892d7ffa4bb3da6ae8a9 David-Wobrock 1509048882 +0200 commit: All files -1ed2db048937886ab77c892d7ffa4bb3da6ae8a9 4c2edb394b46664ac61f0b6fb29e57fe807ce21e David-Wobrock 1509049863 +0200 commit (amend): All files -4c2edb394b46664ac61f0b6fb29e57fe807ce21e 16fd55a08b9ad1af4282cafccf5c14adf1f2a1dc David-Wobrock 1509381987 +0100 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac deleted file mode 100644 index 4d7d160..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/09/d00ce23e0b42f2c18895ee5fa577f57f14b2ac +++ /dev/null @@ -1,3 +0,0 @@ -x]PËjÃ0ìÙ_±�ƒ�;Ôm øRrÈ­·„m­�ZY2zÒ¯¯dåY„˜™�™UÃee™?Ì }L¡•”‰~Öté«G¢¼£@U¤ÐaóU‹^B‘Eö RÀ2/^Ò"O—%O«¼Œ:% ¤³Æ*$Ø0JeÀ -æÌ‘pfœ×QÒÉ/£ÍY7°Þ…1)ô7à•QËk­a¦’«(»€óU�;L0Ãj|(‹£8¢ (Z†ÚŸ“ð89úí|à…ñ67o -Ýú{_&™&=ï�¨¬âu¼¸C;†œê*„a¸“˜Ñø¼U¶¶Fn½4©Ý‹´S­|錊 µ:’o<ž�ÊmÅ~±Úºßs’T�ÔHB‰Ý&žÏï{øÐ$–s2UºFï„ÁUH÷‚)ãÿüájwr>Dqá£& \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/0c/4155a27f085fa8e954384cd3072054781ea238 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/0c/4155a27f085fa8e954384cd3072054781ea238 deleted file mode 100644 index e8c1e71..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/0c/4155a27f085fa8e954384cd3072054781ea238 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/16/fd55a08b9ad1af4282cafccf5c14adf1f2a1dc b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/16/fd55a08b9ad1af4282cafccf5c14adf1f2a1dc deleted file mode 100644 index 36e89fe..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/16/fd55a08b9ad1af4282cafccf5c14adf1f2a1dc +++ /dev/null @@ -1,3 +0,0 @@ -x•ÎM -Â0†a×9Eöb™üOADÁ;¸N2S-¶FjÔëñ.ßoñðå2Ïc•ÚøU]˜%š”}Šˆ �í!xta }*iŸ ™,îqá[• -‘£ ƒ×¬�³5”L°ÃИì˜-8T">ë¥,ò_#mN%-%_å–¾Ù½¹?Ïqœº\æ�Tz°ˆ¨å4€hk;Zù? ê14B5B¦IãÄñøK& \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/18/8d1e847da762e20ec43db374ffba8c5ee40581 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/18/8d1e847da762e20ec43db374ffba8c5ee40581 deleted file mode 100644 index d3792e2..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/18/8d1e847da762e20ec43db374ffba8c5ee40581 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/19/b0fd33394f0a1c56a43446422ec5ef7e9c87e2 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/19/b0fd33394f0a1c56a43446422ec5ef7e9c87e2 deleted file mode 100644 index 6694436..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/19/b0fd33394f0a1c56a43446422ec5ef7e9c87e2 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1e/d2db048937886ab77c892d7ffa4bb3da6ae8a9 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1e/d2db048937886ab77c892d7ffa4bb3da6ae8a9 deleted file mode 100644 index 50c871f..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1e/d2db048937886ab77c892d7ffa4bb3da6ae8a9 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1f/660a3639a3c11ad69f8e7f0fcef1af842778d8 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1f/660a3639a3c11ad69f8e7f0fcef1af842778d8 deleted file mode 100644 index c7d64a3..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/1f/660a3639a3c11ad69f8e7f0fcef1af842778d8 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/27/e9ce4a241beb6bc95a87c57501f5df8bd389c3 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/27/e9ce4a241beb6bc95a87c57501f5df8bd389c3 deleted file mode 100644 index 8613608..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/27/e9ce4a241beb6bc95a87c57501f5df8bd389c3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/3c/9094321361af2955414f87b28796b4c8c42cec b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/3c/9094321361af2955414f87b28796b4c8c42cec deleted file mode 100644 index 8c584b1..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/3c/9094321361af2955414f87b28796b4c8c42cec and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 deleted file mode 100644 index adf6411..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4c/2edb394b46664ac61f0b6fb29e57fe807ce21e b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4c/2edb394b46664ac61f0b6fb29e57fe807ce21e deleted file mode 100644 index c77bc34..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/4c/2edb394b46664ac61f0b6fb29e57fe807ce21e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/53/e59303633e807579d18f4174cb2a3dd3c15157 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/53/e59303633e807579d18f4174cb2a3dd3c15157 deleted file mode 100644 index f7baccd..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/53/e59303633e807579d18f4174cb2a3dd3c15157 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/60/70f2b1c3bce797d6373c9aac3e723af36b1658 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/60/70f2b1c3bce797d6373c9aac3e723af36b1658 deleted file mode 100644 index e267d62..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/60/70f2b1c3bce797d6373c9aac3e723af36b1658 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 deleted file mode 100644 index 3f771d5..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 deleted file mode 100644 index cf19499..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 +++ /dev/null @@ -1 +0,0 @@ -xm�OOA Å=ϧhö‰îãE& Á(ÀxœvºË�Ît3S@¿½Ëžš¦¯ï÷Ú5ñîoŠ¢P_Ëé jŽ�o¡áä£`2‚YL—x‹µÀ¥–JÍð»ãŒdƒp^¶DvM6ƒ…ÀnGxG¸G‚½Mþ4Š6 ƒª²]G¾¶â9VUï÷Ú'{x8 €coî34žð2¢ÚˆtùIkÇu.ÝÖÆ–ÿ2Õ4F=*G#½áƒ°vØÿŒ¢¹õZÏT>tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/6e/ac9768027d572282f4f50c9c8154d081303928 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/6e/ac9768027d572282f4f50c9c8154d081303928 deleted file mode 100644 index 785458e..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/6e/ac9768027d572282f4f50c9c8154d081303928 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/78/76e7751f6ce1a191c135a017afaaece86b6e63 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/78/76e7751f6ce1a191c135a017afaaece86b6e63 deleted file mode 100644 index 6afd695..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/78/76e7751f6ce1a191c135a017afaaece86b6e63 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/83/bc6ba8802549076857fd3a69017dd26b0add3c b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/83/bc6ba8802549076857fd3a69017dd26b0add3c deleted file mode 100644 index 9c9e366..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/83/bc6ba8802549076857fd3a69017dd26b0add3c and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/88/05d565409f35e08d0f55ac83126ed71a021814 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/88/05d565409f35e08d0f55ac83126ed71a021814 deleted file mode 100644 index 8a7f1ef..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/88/05d565409f35e08d0f55ac83126ed71a021814 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/5be9edbe3253011bbcd7c3b0f58e0b23b64006 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/5be9edbe3253011bbcd7c3b0f58e0b23b64006 deleted file mode 100644 index 1ea5b73..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/8c/5be9edbe3253011bbcd7c3b0f58e0b23b64006 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/b9/d7998b28816a1910160972b501976d1c3137e9 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/b9/d7998b28816a1910160972b501976d1c3137e9 deleted file mode 100644 index 76acb00..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/b9/d7998b28816a1910160972b501976d1c3137e9 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/c7/beda138c33c089001615811df53292c56ce647 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/c7/beda138c33c089001615811df53292c56ce647 deleted file mode 100644 index 739a1d5..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/c7/beda138c33c089001615811df53292c56ce647 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/d5/33aa0b42cd49ffe6b9745faf19ed6f688eae48 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/d5/33aa0b42cd49ffe6b9745faf19ed6f688eae48 deleted file mode 100644 index 961bb6a..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/d5/33aa0b42cd49ffe6b9745faf19ed6f688eae48 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/da/51ff0946cae8c000592184b1b05d831692d58f b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/da/51ff0946cae8c000592184b1b05d831692d58f deleted file mode 100644 index 555d7f6..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/da/51ff0946cae8c000592184b1b05d831692d58f and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/db/58264a0a37c4f14e5a616c286fa2f1b215baf3 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/db/58264a0a37c4f14e5a616c286fa2f1b215baf3 deleted file mode 100644 index b51a008..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/db/58264a0a37c4f14e5a616c286fa2f1b215baf3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa deleted file mode 100644 index 02f7652..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/fa/a30528db5930caebddd08ab642f8e4c00a6c60 b/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/fa/a30528db5930caebddd08ab642f8e4c00a6c60 deleted file mode 100644 index ca50370..0000000 --- a/tests/test_project_fixtures/test_project_add_not_null_column_followed_by_default/git/objects/fa/a30528db5930caebddd08ab642f8e4c00a6c60 +++ /dev/null @@ -1,2 +0,0 @@ -x­‘1OÃ0…™ó+Nê�5Q\A@•2 UE ¬,YN|‰Œ;rì"þ=vÜ´…®x|~þÞ½s-u eYÞ, »Í Ñ\¨n ζÙcP’<£BÃ,r¨¿a÷ÉT§�ä„ä%h›‚ 1509046997 +0200 commit (initial): Init -dbb570854ffac36f2c6c83f05b462f488ab9ea2e ba1eccf45ea15453cdb70eccb93febdfeb020b5b David-Wobrock 1509047009 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/logs/refs/heads/master deleted file mode 100644 index a75a602..0000000 --- a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/logs/refs/heads/master +++ /dev/null @@ -1,2 +0,0 @@ -0000000000000000000000000000000000000000 dbb570854ffac36f2c6c83f05b462f488ab9ea2e David-Wobrock 1509046997 +0200 commit (initial): Init -dbb570854ffac36f2c6c83f05b462f488ab9ea2e ba1eccf45ea15453cdb70eccb93febdfeb020b5b David-Wobrock 1509047009 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/1c/10d0afe6768cf62149ccdade6d7c21e9f563c2 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/1c/10d0afe6768cf62149ccdade6d7c21e9f563c2 deleted file mode 100644 index 484862b..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/1c/10d0afe6768cf62149ccdade6d7c21e9f563c2 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 deleted file mode 100644 index adf6411..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 deleted file mode 100644 index 3f771d5..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 deleted file mode 100644 index cf19499..0000000 --- a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 +++ /dev/null @@ -1 +0,0 @@ -xm�OOA Å=ϧhö‰îãE& Á(ÀxœvºË�Ît3S@¿½Ëžš¦¯ï÷Ú5ñîoŠ¢P_Ëé jŽ�o¡áä£`2‚YL—x‹µÀ¥–JÍð»ãŒdƒp^¶DvM6ƒ…ÀnGxG¸G‚½Mþ4Š6 ƒª²]G¾¶â9VUï÷Ú'{x8 €coî34žð2¢ÚˆtùIkÇu.ÝÖÆ–ÿ2Õ4F=*G#½áƒ°vØÿŒ¢¹õZÏT>tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/6f/60aa19497fb69e565a609b77a9d9a153ce5166 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/6f/60aa19497fb69e565a609b77a9d9a153ce5166 deleted file mode 100644 index f83db9c..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/6f/60aa19497fb69e565a609b77a9d9a153ce5166 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/76/cc5dc6375ab11196a4a33e8483e90a4644cca6 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/76/cc5dc6375ab11196a4a33e8483e90a4644cca6 deleted file mode 100644 index 27897af..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/76/cc5dc6375ab11196a4a33e8483e90a4644cca6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/cafd52dbcbcf6381c02cf1f7de90dbfa1a43cc b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/cafd52dbcbcf6381c02cf1f7de90dbfa1a43cc deleted file mode 100644 index 4308bad..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/cafd52dbcbcf6381c02cf1f7de90dbfa1a43cc and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/9f/a7aec38f3098aa3035f03195a084ca8c2a6fd4 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/9f/a7aec38f3098aa3035f03195a084ca8c2a6fd4 deleted file mode 100644 index 0027b71..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/9f/a7aec38f3098aa3035f03195a084ca8c2a6fd4 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/ba/1eccf45ea15453cdb70eccb93febdfeb020b5b b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/ba/1eccf45ea15453cdb70eccb93febdfeb020b5b deleted file mode 100644 index 92eda4a..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/ba/1eccf45ea15453cdb70eccb93febdfeb020b5b and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/7815c8d2a6f36f5ee21d79ca061aac9eda3096 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/7815c8d2a6f36f5ee21d79ca061aac9eda3096 deleted file mode 100644 index acbb322..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/7815c8d2a6f36f5ee21d79ca061aac9eda3096 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/91b69ccab5441e2fdb073dcafb869e88c9aa6b b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/91b69ccab5441e2fdb073dcafb869e88c9aa6b deleted file mode 100644 index 873eba0..0000000 --- a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/d3/91b69ccab5441e2fdb073dcafb869e88c9aa6b +++ /dev/null @@ -1,2 +0,0 @@ -x]P±nÂ0윯xCBE"B¡THP[· -YNü¹uìÈv*ѯ¯(õ`Yw÷î„Õrõ0�ô1…J1.› ô¶N_<Mà %jj‘Ay†Ý'•�‚<Ëó씄Å<_§ù<]¬ Ú,×Q­U „Ô½í5¼í”¶ÐKîÌ‘n�›0Q²Á/cå¨ky㸒f­ðʨÔ8ŽTreWpº‰"p‡Kn9PÀ»î1` ;” eÅÑ8âcž§:¿�¼2ÞæOÄ«F·þÑ—I†IÏû#i‹E¼�gwhÍQ0S„� ws�[eÛÞª½—&Ô½H5„°Â—žA§yKõ™|áù‚Ôn+þƒÅÞýž“|£.•AJvñtzßÇ&±T–È^2ԺŤÅuhðôtsº˜ž¢_2á¡G \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/db/b570854ffac36f2c6c83f05b462f488ab9ea2e b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/db/b570854ffac36f2c6c83f05b462f488ab9ea2e deleted file mode 100644 index 0fea269..0000000 --- a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/db/b570854ffac36f2c6c83f05b462f488ab9ea2e +++ /dev/null @@ -1 +0,0 @@ -x¥�1!E­9ÅôÆÍ,BbÌ6žÀš�Y%+’V¯/Æ#X¾Ÿ¼ÿBÉ95í~Ó*3(²RÇ`” d˜œGƒ¬Í6'­�‰Y9T¯í^*œý+ÅݵP-a�cüâðþátË>=†Pò F�Ý2Î`‹Qôµ‡ÿq!.ÏÔÄ(‹< \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/de/2a6fb35877e85acd92f4871e5fd18783ae0c3f b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/de/2a6fb35877e85acd92f4871e5fd18783ae0c3f deleted file mode 100644 index 3de107b..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/de/2a6fb35877e85acd92f4871e5fd18783ae0c3f and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 deleted file mode 100644 index a0339be..0000000 Binary files a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/refs/heads/master b/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/refs/heads/master deleted file mode 100644 index 2cb9811..0000000 --- a/tests/test_project_fixtures/test_project_create_table_with_not_null_column/git/refs/heads/master +++ /dev/null @@ -1 +0,0 @@ -ba1eccf45ea15453cdb70eccb93febdfeb020b5b diff --git a/tests/test_project_fixtures/test_project_drop_column/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_drop_column/git/COMMIT_EDITMSG deleted file mode 100644 index 3b5cc13..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/COMMIT_EDITMSG +++ /dev/null @@ -1,22 +0,0 @@ -All files - -# Veuillez saisir le message de validation pour vos modifications. Les lignes -# commençant par '#' seront ignorées, et un message vide abandonne la validation. -# Sur la branche master -# Modifications qui seront validées : -# nouveau fichier: .gitignore -# nouveau fichier: manage.py -# nouveau fichier: test_app/__init__.py -# nouveau fichier: test_app/admin.py -# nouveau fichier: test_app/apps.py -# nouveau fichier: test_app/migrations/0001_create_table.py -# nouveau fichier: test_app/migrations/0002_drop_column.py -# nouveau fichier: test_app/migrations/__init__.py -# nouveau fichier: test_app/models.py -# nouveau fichier: test_app/tests.py -# nouveau fichier: test_app/views.py -# nouveau fichier: test_project_drop_column/__init__.py -# nouveau fichier: test_project_drop_column/settings.py -# nouveau fichier: test_project_drop_column/urls.py -# nouveau fichier: test_project_drop_column/wsgi.py -# diff --git a/tests/test_project_fixtures/test_project_drop_column/git/HEAD b/tests/test_project_fixtures/test_project_drop_column/git/HEAD deleted file mode 100644 index cb089cd..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/HEAD +++ /dev/null @@ -1 +0,0 @@ -ref: refs/heads/master diff --git a/tests/test_project_fixtures/test_project_drop_column/git/config b/tests/test_project_fixtures/test_project_drop_column/git/config deleted file mode 100644 index eeb8dd7..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/config +++ /dev/null @@ -1,5 +0,0 @@ -[core] - repositoryformatversion = 0 - filemode = false - bare = false - logallrefupdates = true diff --git a/tests/test_project_fixtures/test_project_drop_column/git/description b/tests/test_project_fixtures/test_project_drop_column/git/description deleted file mode 100644 index 498b267..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/description +++ /dev/null @@ -1 +0,0 @@ -Unnamed repository; edit this file 'description' to name the repository. diff --git a/tests/test_project_fixtures/test_project_drop_column/git/index b/tests/test_project_fixtures/test_project_drop_column/git/index deleted file mode 100644 index b7a985f..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/index and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/info/exclude b/tests/test_project_fixtures/test_project_drop_column/git/info/exclude deleted file mode 100644 index a5196d1..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/info/exclude +++ /dev/null @@ -1,6 +0,0 @@ -# git ls-files --others --exclude-from=.git/info/exclude -# Lines that start with '#' are comments. -# For a project mostly in C, the following would be a good set of -# exclude patterns (uncomment them if you want to use them): -# *.[oa] -# *~ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/logs/HEAD b/tests/test_project_fixtures/test_project_drop_column/git/logs/HEAD deleted file mode 100644 index e0c0e72..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/logs/HEAD +++ /dev/null @@ -1,3 +0,0 @@ -0000000000000000000000000000000000000000 6a34c365ae581e0bd73521ffc69021e039d54d19 David-Wobrock 1509047306 +0200 commit (initial): Init -6a34c365ae581e0bd73521ffc69021e039d54d19 424a54e5916970e0c48fdcefc707b00d07d8190a David-Wobrock 1509047317 +0200 commit: All files -424a54e5916970e0c48fdcefc707b00d07d8190a 24f18b5897f6361405dd5c1c900869d693430801 David-Wobrock 1509047363 +0200 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_drop_column/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_drop_column/git/logs/refs/heads/master deleted file mode 100644 index e0c0e72..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/logs/refs/heads/master +++ /dev/null @@ -1,3 +0,0 @@ -0000000000000000000000000000000000000000 6a34c365ae581e0bd73521ffc69021e039d54d19 David-Wobrock 1509047306 +0200 commit (initial): Init -6a34c365ae581e0bd73521ffc69021e039d54d19 424a54e5916970e0c48fdcefc707b00d07d8190a David-Wobrock 1509047317 +0200 commit: All files -424a54e5916970e0c48fdcefc707b00d07d8190a 24f18b5897f6361405dd5c1c900869d693430801 David-Wobrock 1509047363 +0200 commit (amend): All files diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/03/0a39f4edf75b9d3a5506a722b3726296a87ef4 b/tests/test_project_fixtures/test_project_drop_column/git/objects/03/0a39f4edf75b9d3a5506a722b3726296a87ef4 deleted file mode 100644 index cb2bc2b..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/03/0a39f4edf75b9d3a5506a722b3726296a87ef4 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/1f/c7cd90b9ed61da4f88a4455d34977143489aa7 b/tests/test_project_fixtures/test_project_drop_column/git/objects/1f/c7cd90b9ed61da4f88a4455d34977143489aa7 deleted file mode 100644 index d25ba48..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/1f/c7cd90b9ed61da4f88a4455d34977143489aa7 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/24/f18b5897f6361405dd5c1c900869d693430801 b/tests/test_project_fixtures/test_project_drop_column/git/objects/24/f18b5897f6361405dd5c1c900869d693430801 deleted file mode 100644 index e033d63..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/24/f18b5897f6361405dd5c1c900869d693430801 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/37/8f8dec7827972177bb4f79b05a508afe2fbb65 b/tests/test_project_fixtures/test_project_drop_column/git/objects/37/8f8dec7827972177bb4f79b05a508afe2fbb65 deleted file mode 100644 index 0649b52..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/37/8f8dec7827972177bb4f79b05a508afe2fbb65 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/42/4a54e5916970e0c48fdcefc707b00d07d8190a b/tests/test_project_fixtures/test_project_drop_column/git/objects/42/4a54e5916970e0c48fdcefc707b00d07d8190a deleted file mode 100644 index 8f82a1d..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/42/4a54e5916970e0c48fdcefc707b00d07d8190a and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 b/tests/test_project_fixtures/test_project_drop_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 deleted file mode 100644 index adf6411..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/4c/14a9e6112b6f7648ab793c423cdf598431fa93 b/tests/test_project_fixtures/test_project_drop_column/git/objects/4c/14a9e6112b6f7648ab793c423cdf598431fa93 deleted file mode 100644 index 9580adc..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/4c/14a9e6112b6f7648ab793c423cdf598431fa93 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/5a/6a22e2af1152c5fb11a8a3e94eac9a21612b22 b/tests/test_project_fixtures/test_project_drop_column/git/objects/5a/6a22e2af1152c5fb11a8a3e94eac9a21612b22 deleted file mode 100644 index 9f46cf2..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/5a/6a22e2af1152c5fb11a8a3e94eac9a21612b22 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/62/ba4ba170fdcc4677c50b5155980671d1dc8776 b/tests/test_project_fixtures/test_project_drop_column/git/objects/62/ba4ba170fdcc4677c50b5155980671d1dc8776 deleted file mode 100644 index 47f128e..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/62/ba4ba170fdcc4677c50b5155980671d1dc8776 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 b/tests/test_project_fixtures/test_project_drop_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 deleted file mode 100644 index 3f771d5..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 b/tests/test_project_fixtures/test_project_drop_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 deleted file mode 100644 index cf19499..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 +++ /dev/null @@ -1 +0,0 @@ -xm�OOA Å=ϧhö‰îãE& Á(ÀxœvºË�Ît3S@¿½Ëžš¦¯ï÷Ú5ñîoŠ¢P_Ëé jŽ�o¡áä£`2‚YL—x‹µÀ¥–JÍð»ãŒdƒp^¶DvM6ƒ…ÀnGxG¸G‚½Mþ4Š6 ƒª²]G¾¶â9VUï÷Ú'{x8 €coî34žð2¢ÚˆtùIkÇu.ÝÖÆ–ÿ2Õ4F=*G#½áƒ°vØÿŒ¢¹õZÏT>tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/6a/34c365ae581e0bd73521ffc69021e039d54d19 b/tests/test_project_fixtures/test_project_drop_column/git/objects/6a/34c365ae581e0bd73521ffc69021e039d54d19 deleted file mode 100644 index b36c27a..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/objects/6a/34c365ae581e0bd73521ffc69021e039d54d19 +++ /dev/null @@ -1 +0,0 @@ -x¥�1!E­9ÅôÆÍ, ‰ÙXØxkf•(’V¯/Æ#X¾Ÿ¼ÿBÉ95í´i•Y©c0J2LΣAÖŠ�“Ö.Ĭ*á×v+Nþ•âîR¨–p‡Cüâðþáñš}z ¡äF�ÝÚOh`‹Qôµ‡ÿq!ÎÏÔÄ"Ö;ç \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_drop_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/7a/9637de11249631dbaeebc348bf69a235dfbd34 b/tests/test_project_fixtures/test_project_drop_column/git/objects/7a/9637de11249631dbaeebc348bf69a235dfbd34 deleted file mode 100644 index fbb70e0..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/7a/9637de11249631dbaeebc348bf69a235dfbd34 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_drop_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_drop_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_drop_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e b/tests/test_project_fixtures/test_project_drop_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e deleted file mode 100644 index 13fc88e..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/95/a7313de6fcb6553cd7a0e4993ee1c6c2760d0e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/a4/b2b15bde4d6744a83c82f5c27287dc2ffd0f39 b/tests/test_project_fixtures/test_project_drop_column/git/objects/a4/b2b15bde4d6744a83c82f5c27287dc2ffd0f39 deleted file mode 100644 index 16d025e..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/objects/a4/b2b15bde4d6744a83c82f5c27287dc2ffd0f39 +++ /dev/null @@ -1,4 +0,0 @@ -x]PËjÃ0ìY_±�ƒ�›8mÒð!4¤ä�[o%ÙZµ²d$¹�~}%+�¶:13;3«Jê -–Ëùݲû jÍ…j×0¸&{™À+*4Ì!‡êÛ¦Z E^ù -´‚żxÊŠy¶XBñ¸~X‘Æè(m7¤D×kã`P›#•Ây7iIòÑ/çÕE׉և ­ì :?”¤–ÌZ8\¨ô&ʯàtMø#”p‚I(áÍ 1Ž=*Žªh=ñ> -�‘Ó}Ø.^™`ó+âÅ _ÿʤãdàÃQ¬Ã2Ù$³?h#Pr[Æ�(Œwšž\¶Ê7ƒÓ» M™Ñz áe(=ƒÞˆŽ™ýÄÓ±hüVâË�ÿ=/ùBSi‹4–Øo“éôo�š&j�’Ž•nÑ{å°EÓƒ`Ìø?¼Ù���äy`£* \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/bf/21b1d9dc89a31ac4f2f6260996da59814e2f1e b/tests/test_project_fixtures/test_project_drop_column/git/objects/bf/21b1d9dc89a31ac4f2f6260996da59814e2f1e deleted file mode 100644 index bf5a515..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/bf/21b1d9dc89a31ac4f2f6260996da59814e2f1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 b/tests/test_project_fixtures/test_project_drop_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 deleted file mode 100644 index 61838b7..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/d4/942ceb12ecd35cfbb0d21fee3062c019e659c3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/dd/58746c94048ea2fe86d773395b68803c4ef832 b/tests/test_project_fixtures/test_project_drop_column/git/objects/dd/58746c94048ea2fe86d773395b68803c4ef832 deleted file mode 100644 index 9670018..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/dd/58746c94048ea2fe86d773395b68803c4ef832 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_drop_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 b/tests/test_project_fixtures/test_project_drop_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 deleted file mode 100644 index a0339be..0000000 Binary files a/tests/test_project_fixtures/test_project_drop_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_drop_column/git/refs/heads/master b/tests/test_project_fixtures/test_project_drop_column/git/refs/heads/master deleted file mode 100644 index e48b674..0000000 --- a/tests/test_project_fixtures/test_project_drop_column/git/refs/heads/master +++ /dev/null @@ -1 +0,0 @@ -24f18b5897f6361405dd5c1c900869d693430801 diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_multi_commit/git/COMMIT_EDITMSG index 822b1e1..122f5dd 100644 --- a/tests/test_project_fixtures/test_project_multi_commit/git/COMMIT_EDITMSG +++ b/tests/test_project_fixtures/test_project_multi_commit/git/COMMIT_EDITMSG @@ -1,10 +1 @@ -Add accepted migration - -# Veuillez saisir le message de validation pour vos modifications. Les lignes -# commençant par '#' seront ignorées, et un message vide abandonne la validation. -# Sur la branche master -# Modifications qui seront validées : -# nouveau fichier: test_app/migrations/0003_add_new_nullable_field.py -# modifié: test_app/models.py -# modifié: test_project_multi_commit/settings.py -# +Backward compatible migrations diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/applypatch-msg.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/applypatch-msg.sample new file mode 100644 index 0000000..8b2a2fe --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/applypatch-msg.sample @@ -0,0 +1,15 @@ +#!/bin/sh +# +# An example hook script to check the commit log message taken by +# applypatch from an e-mail message. +# +# The hook should exit with non-zero status after issuing an +# appropriate message if it wants to stop the commit. The hook is +# allowed to edit the commit message file. +# +# To enable this hook, rename this file to "applypatch-msg". + +. git-sh-setup +test -x "$GIT_DIR/hooks/commit-msg" && + exec "$GIT_DIR/hooks/commit-msg" ${1+"$@"} +: diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/commit-msg.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/commit-msg.sample new file mode 100644 index 0000000..b58d118 --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/commit-msg.sample @@ -0,0 +1,24 @@ +#!/bin/sh +# +# An example hook script to check the commit log message. +# Called by "git commit" with one argument, the name of the file +# that has the commit message. The hook should exit with non-zero +# status after issuing an appropriate message if it wants to stop the +# commit. The hook is allowed to edit the commit message file. +# +# To enable this hook, rename this file to "commit-msg". + +# Uncomment the below to add a Signed-off-by line to the message. +# Doing this in a hook is a bad idea in general, but the prepare-commit-msg +# hook is more suited to it. +# +# SOB=$(git var GIT_AUTHOR_IDENT | sed -n 's/^\(.*>\).*$/Signed-off-by: \1/p') +# grep -qs "^$SOB" "$1" || echo "$SOB" >> "$1" + +# This example catches duplicate Signed-off-by lines. + +test "" = "$(grep '^Signed-off-by: ' "$1" | + sort | uniq -c | sed -e '/^[ ]*1[ ]/d')" || { + echo >&2 Duplicate Signed-off-by lines. + exit 1 +} diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/post-update.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/post-update.sample new file mode 100644 index 0000000..ec17ec1 --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/post-update.sample @@ -0,0 +1,8 @@ +#!/bin/sh +# +# An example hook script to prepare a packed repository for use over +# dumb transports. +# +# To enable this hook, rename this file to "post-update". + +exec git update-server-info diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-applypatch.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-applypatch.sample new file mode 100644 index 0000000..b1f187c --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-applypatch.sample @@ -0,0 +1,14 @@ +#!/bin/sh +# +# An example hook script to verify what is about to be committed +# by applypatch from an e-mail message. +# +# The hook should exit with non-zero status after issuing an +# appropriate message if it wants to stop the commit. +# +# To enable this hook, rename this file to "pre-applypatch". + +. git-sh-setup +test -x "$GIT_DIR/hooks/pre-commit" && + exec "$GIT_DIR/hooks/pre-commit" ${1+"$@"} +: diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-commit.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-commit.sample new file mode 100644 index 0000000..68d62d5 --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-commit.sample @@ -0,0 +1,49 @@ +#!/bin/sh +# +# An example hook script to verify what is about to be committed. +# Called by "git commit" with no arguments. The hook should +# exit with non-zero status after issuing an appropriate message if +# it wants to stop the commit. +# +# To enable this hook, rename this file to "pre-commit". + +if git rev-parse --verify HEAD >/dev/null 2>&1 +then + against=HEAD +else + # Initial commit: diff against an empty tree object + against=4b825dc642cb6eb9a060e54bf8d69288fbee4904 +fi + +# If you want to allow non-ASCII filenames set this variable to true. +allownonascii=$(git config --bool hooks.allownonascii) + +# Redirect output to stderr. +exec 1>&2 + +# Cross platform projects tend to avoid non-ASCII filenames; prevent +# them from being added to the repository. We exploit the fact that the +# printable range starts at the space character and ends with tilde. +if [ "$allownonascii" != "true" ] && + # Note that the use of brackets around a tr range is ok here, (it's + # even required, for portability to Solaris 10's /usr/bin/tr), since + # the square bracket bytes happen to fall in the designated range. + test $(git diff --cached --name-only --diff-filter=A -z $against | + LC_ALL=C tr -d '[ -~]\0' | wc -c) != 0 +then + cat <<\EOF +Error: Attempt to add a non-ASCII file name. + +This can cause problems if you want to work with people on other platforms. + +To be portable it is advisable to rename the file. + +If you know what you are doing you can disable this check using: + + git config hooks.allownonascii true +EOF + exit 1 +fi + +# If there are whitespace errors, print the offending file names and fail. +exec git diff-index --check --cached $against -- diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-push.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-push.sample new file mode 100644 index 0000000..1f3bceb --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-push.sample @@ -0,0 +1,54 @@ +#!/bin/sh + +# An example hook script to verify what is about to be pushed. Called by "git +# push" after it has checked the remote status, but before anything has been +# pushed. If this script exits with a non-zero status nothing will be pushed. +# +# This hook is called with the following parameters: +# +# $1 -- Name of the remote to which the push is being done +# $2 -- URL to which the push is being done +# +# If pushing without using a named remote those arguments will be equal. +# +# Information about the commits which are being pushed is supplied as lines to +# the standard input in the form: +# +# +# +# This sample shows how to prevent push of commits where the log message starts +# with "WIP" (work in progress). + +remote="$1" +url="$2" + +z40=0000000000000000000000000000000000000000 + +IFS=' ' +while read local_ref local_sha remote_ref remote_sha +do + if [ "$local_sha" = $z40 ] + then + # Handle delete + : + else + if [ "$remote_sha" = $z40 ] + then + # New branch, examine all commits + range="$local_sha" + else + # Update to existing branch, examine new commits + range="$remote_sha..$local_sha" + fi + + # Check for WIP commit + commit=`git rev-list -n 1 --grep '^WIP' "$range"` + if [ -n "$commit" ] + then + echo "Found WIP commit in $local_ref, not pushing" + exit 1 + fi + fi +done + +exit 0 diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-rebase.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-rebase.sample new file mode 100644 index 0000000..33730ca --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/pre-rebase.sample @@ -0,0 +1,169 @@ +#!/bin/sh +# +# Copyright (c) 2006, 2008 Junio C Hamano +# +# The "pre-rebase" hook is run just before "git rebase" starts doing +# its job, and can prevent the command from running by exiting with +# non-zero status. +# +# The hook is called with the following parameters: +# +# $1 -- the upstream the series was forked from. +# $2 -- the branch being rebased (or empty when rebasing the current branch). +# +# This sample shows how to prevent topic branches that are already +# merged to 'next' branch from getting rebased, because allowing it +# would result in rebasing already published history. + +publish=next +basebranch="$1" +if test "$#" = 2 +then + topic="refs/heads/$2" +else + topic=`git symbolic-ref HEAD` || + exit 0 ;# we do not interrupt rebasing detached HEAD +fi + +case "$topic" in +refs/heads/??/*) + ;; +*) + exit 0 ;# we do not interrupt others. + ;; +esac + +# Now we are dealing with a topic branch being rebased +# on top of master. Is it OK to rebase it? + +# Does the topic really exist? +git show-ref -q "$topic" || { + echo >&2 "No such branch $topic" + exit 1 +} + +# Is topic fully merged to master? +not_in_master=`git rev-list --pretty=oneline ^master "$topic"` +if test -z "$not_in_master" +then + echo >&2 "$topic is fully merged to master; better remove it." + exit 1 ;# we could allow it, but there is no point. +fi + +# Is topic ever merged to next? If so you should not be rebasing it. +only_next_1=`git rev-list ^master "^$topic" ${publish} | sort` +only_next_2=`git rev-list ^master ${publish} | sort` +if test "$only_next_1" = "$only_next_2" +then + not_in_topic=`git rev-list "^$topic" master` + if test -z "$not_in_topic" + then + echo >&2 "$topic is already up-to-date with master" + exit 1 ;# we could allow it, but there is no point. + else + exit 0 + fi +else + not_in_next=`git rev-list --pretty=oneline ^${publish} "$topic"` + /usr/bin/perl -e ' + my $topic = $ARGV[0]; + my $msg = "* $topic has commits already merged to public branch:\n"; + my (%not_in_next) = map { + /^([0-9a-f]+) /; + ($1 => 1); + } split(/\n/, $ARGV[1]); + for my $elem (map { + /^([0-9a-f]+) (.*)$/; + [$1 => $2]; + } split(/\n/, $ARGV[2])) { + if (!exists $not_in_next{$elem->[0]}) { + if ($msg) { + print STDERR $msg; + undef $msg; + } + print STDERR " $elem->[1]\n"; + } + } + ' "$topic" "$not_in_next" "$not_in_master" + exit 1 +fi + +<<\DOC_END + +This sample hook safeguards topic branches that have been +published from being rewound. + +The workflow assumed here is: + + * Once a topic branch forks from "master", "master" is never + merged into it again (either directly or indirectly). + + * Once a topic branch is fully cooked and merged into "master", + it is deleted. If you need to build on top of it to correct + earlier mistakes, a new topic branch is created by forking at + the tip of the "master". This is not strictly necessary, but + it makes it easier to keep your history simple. + + * Whenever you need to test or publish your changes to topic + branches, merge them into "next" branch. + +The script, being an example, hardcodes the publish branch name +to be "next", but it is trivial to make it configurable via +$GIT_DIR/config mechanism. + +With this workflow, you would want to know: + +(1) ... if a topic branch has ever been merged to "next". Young + topic branches can have stupid mistakes you would rather + clean up before publishing, and things that have not been + merged into other branches can be easily rebased without + affecting other people. But once it is published, you would + not want to rewind it. + +(2) ... if a topic branch has been fully merged to "master". + Then you can delete it. More importantly, you should not + build on top of it -- other people may already want to + change things related to the topic as patches against your + "master", so if you need further changes, it is better to + fork the topic (perhaps with the same name) afresh from the + tip of "master". + +Let's look at this example: + + o---o---o---o---o---o---o---o---o---o "next" + / / / / + / a---a---b A / / + / / / / + / / c---c---c---c B / + / / / \ / + / / / b---b C \ / + / / / / \ / + ---o---o---o---o---o---o---o---o---o---o---o "master" + + +A, B and C are topic branches. + + * A has one fix since it was merged up to "next". + + * B has finished. It has been fully merged up to "master" and "next", + and is ready to be deleted. + + * C has not merged to "next" at all. + +We would want to allow C to be rebased, refuse A, and encourage +B to be deleted. + +To compute (1): + + git rev-list ^master ^topic next + git rev-list ^master next + + if these match, topic has not merged in next at all. + +To compute (2): + + git rev-list master..topic + + if this is empty, it is fully merged to "master". + +DOC_END diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/prepare-commit-msg.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/prepare-commit-msg.sample new file mode 100644 index 0000000..f093a02 --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/prepare-commit-msg.sample @@ -0,0 +1,36 @@ +#!/bin/sh +# +# An example hook script to prepare the commit log message. +# Called by "git commit" with the name of the file that has the +# commit message, followed by the description of the commit +# message's source. The hook's purpose is to edit the commit +# message file. If the hook fails with a non-zero status, +# the commit is aborted. +# +# To enable this hook, rename this file to "prepare-commit-msg". + +# This hook includes three examples. The first comments out the +# "Conflicts:" part of a merge commit. +# +# The second includes the output of "git diff --name-status -r" +# into the message, just before the "git status" output. It is +# commented because it doesn't cope with --amend or with squashed +# commits. +# +# The third example adds a Signed-off-by line to the message, that can +# still be edited. This is rarely a good idea. + +case "$2,$3" in + merge,) + /usr/bin/perl -i.bak -ne 's/^/# /, s/^# #/#/ if /^Conflicts/ .. /#/; print' "$1" ;; + +# ,|template,) +# /usr/bin/perl -i.bak -pe ' +# print "\n" . `git diff --cached --name-status -r` +# if /^#/ && $first++ == 0' "$1" ;; + + *) ;; +esac + +# SOB=$(git var GIT_AUTHOR_IDENT | sed -n 's/^\(.*>\).*$/Signed-off-by: \1/p') +# grep -qs "^$SOB" "$1" || echo "$SOB" >> "$1" diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/hooks/update.sample b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/update.sample new file mode 100644 index 0000000..d847583 --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/hooks/update.sample @@ -0,0 +1,128 @@ +#!/bin/sh +# +# An example hook script to blocks unannotated tags from entering. +# Called by "git receive-pack" with arguments: refname sha1-old sha1-new +# +# To enable this hook, rename this file to "update". +# +# Config +# ------ +# hooks.allowunannotated +# This boolean sets whether unannotated tags will be allowed into the +# repository. By default they won't be. +# hooks.allowdeletetag +# This boolean sets whether deleting tags will be allowed in the +# repository. By default they won't be. +# hooks.allowmodifytag +# This boolean sets whether a tag may be modified after creation. By default +# it won't be. +# hooks.allowdeletebranch +# This boolean sets whether deleting branches will be allowed in the +# repository. By default they won't be. +# hooks.denycreatebranch +# This boolean sets whether remotely creating branches will be denied +# in the repository. By default this is allowed. +# + +# --- Command line +refname="$1" +oldrev="$2" +newrev="$3" + +# --- Safety check +if [ -z "$GIT_DIR" ]; then + echo "Don't run this script from the command line." >&2 + echo " (if you want, you could supply GIT_DIR then run" >&2 + echo " $0 )" >&2 + exit 1 +fi + +if [ -z "$refname" -o -z "$oldrev" -o -z "$newrev" ]; then + echo "usage: $0 " >&2 + exit 1 +fi + +# --- Config +allowunannotated=$(git config --bool hooks.allowunannotated) +allowdeletebranch=$(git config --bool hooks.allowdeletebranch) +denycreatebranch=$(git config --bool hooks.denycreatebranch) +allowdeletetag=$(git config --bool hooks.allowdeletetag) +allowmodifytag=$(git config --bool hooks.allowmodifytag) + +# check for no description +projectdesc=$(sed -e '1q' "$GIT_DIR/description") +case "$projectdesc" in +"Unnamed repository"* | "") + echo "*** Project description file hasn't been set" >&2 + exit 1 + ;; +esac + +# --- Check types +# if $newrev is 0000...0000, it's a commit to delete a ref. +zero="0000000000000000000000000000000000000000" +if [ "$newrev" = "$zero" ]; then + newrev_type=delete +else + newrev_type=$(git cat-file -t $newrev) +fi + +case "$refname","$newrev_type" in + refs/tags/*,commit) + # un-annotated tag + short_refname=${refname##refs/tags/} + if [ "$allowunannotated" != "true" ]; then + echo "*** The un-annotated tag, $short_refname, is not allowed in this repository" >&2 + echo "*** Use 'git tag [ -a | -s ]' for tags you want to propagate." >&2 + exit 1 + fi + ;; + refs/tags/*,delete) + # delete tag + if [ "$allowdeletetag" != "true" ]; then + echo "*** Deleting a tag is not allowed in this repository" >&2 + exit 1 + fi + ;; + refs/tags/*,tag) + # annotated tag + if [ "$allowmodifytag" != "true" ] && git rev-parse $refname > /dev/null 2>&1 + then + echo "*** Tag '$refname' already exists." >&2 + echo "*** Modifying a tag is not allowed in this repository." >&2 + exit 1 + fi + ;; + refs/heads/*,commit) + # branch + if [ "$oldrev" = "$zero" -a "$denycreatebranch" = "true" ]; then + echo "*** Creating a branch is not allowed in this repository" >&2 + exit 1 + fi + ;; + refs/heads/*,delete) + # delete branch + if [ "$allowdeletebranch" != "true" ]; then + echo "*** Deleting a branch is not allowed in this repository" >&2 + exit 1 + fi + ;; + refs/remotes/*,commit) + # tracking branch + ;; + refs/remotes/*,delete) + # delete tracking branch + if [ "$allowdeletebranch" != "true" ]; then + echo "*** Deleting a tracking branch is not allowed in this repository" >&2 + exit 1 + fi + ;; + *) + # Anything else (is there anything else?) + echo "*** Update hook: unknown type of update to ref $refname of type $newrev_type" >&2 + exit 1 + ;; +esac + +# --- Finished +exit 0 diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/index b/tests/test_project_fixtures/test_project_multi_commit/git/index index 54ffd1c..467960d 100644 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/index and b/tests/test_project_fixtures/test_project_multi_commit/git/index differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/logs/HEAD b/tests/test_project_fixtures/test_project_multi_commit/git/logs/HEAD index afe94b7..d0cd6b0 100644 --- a/tests/test_project_fixtures/test_project_multi_commit/git/logs/HEAD +++ b/tests/test_project_fixtures/test_project_multi_commit/git/logs/HEAD @@ -1,4 +1,3 @@ -0000000000000000000000000000000000000000 39d82d794ccb9af40a19c1b708eea6f90695c4d8 David-Wobrock 1509050010 +0200 commit (initial): Init -39d82d794ccb9af40a19c1b708eea6f90695c4d8 44330921696018f8f1480df897b38310549982cb David-Wobrock 1509050030 +0200 commit: All files -44330921696018f8f1480df897b38310549982cb fe961bc4402a57bace36648e1a6f1998bae3c5e3 David-Wobrock 1509050084 +0200 commit: Add accepted migration -fe961bc4402a57bace36648e1a6f1998bae3c5e3 dc16039b7458a98bcf9be2b92389e176ae1d9461 David-Wobrock 1509381925 +0100 commit (amend): Add accepted migration +0000000000000000000000000000000000000000 dbd8d7899446de17d8cf8e57aa7eddb1433bc9c3 David-Wobrock 1511996012 +0100 commit (initial): Init +dbd8d7899446de17d8cf8e57aa7eddb1433bc9c3 d7125d5f4f0cc9623f670a66c54f131acc50032d David-Wobrock 1511996033 +0100 commit: Not working stuff +d7125d5f4f0cc9623f670a66c54f131acc50032d 1021d98b5943db56122c1f848f371ddc38788d0f David-Wobrock 1511996049 +0100 commit: Backward compatible migrations diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_multi_commit/git/logs/refs/heads/master index afe94b7..d0cd6b0 100644 --- a/tests/test_project_fixtures/test_project_multi_commit/git/logs/refs/heads/master +++ b/tests/test_project_fixtures/test_project_multi_commit/git/logs/refs/heads/master @@ -1,4 +1,3 @@ -0000000000000000000000000000000000000000 39d82d794ccb9af40a19c1b708eea6f90695c4d8 David-Wobrock 1509050010 +0200 commit (initial): Init -39d82d794ccb9af40a19c1b708eea6f90695c4d8 44330921696018f8f1480df897b38310549982cb David-Wobrock 1509050030 +0200 commit: All files -44330921696018f8f1480df897b38310549982cb fe961bc4402a57bace36648e1a6f1998bae3c5e3 David-Wobrock 1509050084 +0200 commit: Add accepted migration -fe961bc4402a57bace36648e1a6f1998bae3c5e3 dc16039b7458a98bcf9be2b92389e176ae1d9461 David-Wobrock 1509381925 +0100 commit (amend): Add accepted migration +0000000000000000000000000000000000000000 dbd8d7899446de17d8cf8e57aa7eddb1433bc9c3 David-Wobrock 1511996012 +0100 commit (initial): Init +dbd8d7899446de17d8cf8e57aa7eddb1433bc9c3 d7125d5f4f0cc9623f670a66c54f131acc50032d David-Wobrock 1511996033 +0100 commit: Not working stuff +d7125d5f4f0cc9623f670a66c54f131acc50032d 1021d98b5943db56122c1f848f371ddc38788d0f David-Wobrock 1511996049 +0100 commit: Backward compatible migrations diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/10/21d98b5943db56122c1f848f371ddc38788d0f b/tests/test_project_fixtures/test_project_multi_commit/git/objects/10/21d98b5943db56122c1f848f371ddc38788d0f new file mode 100644 index 0000000..66e3ca3 Binary files /dev/null and b/tests/test_project_fixtures/test_project_multi_commit/git/objects/10/21d98b5943db56122c1f848f371ddc38788d0f differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/39/d82d794ccb9af40a19c1b708eea6f90695c4d8 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/39/d82d794ccb9af40a19c1b708eea6f90695c4d8 deleted file mode 100644 index 57e787d..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/39/d82d794ccb9af40a19c1b708eea6f90695c4d8 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 deleted file mode 100644 index 003a2f3..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/44/330921696018f8f1480df897b38310549982cb b/tests/test_project_fixtures/test_project_multi_commit/git/objects/44/330921696018f8f1480df897b38310549982cb deleted file mode 100644 index c7466f4..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/44/330921696018f8f1480df897b38310549982cb and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/48/345f2d283caadec9aba8c78268ff6c48711836 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/48/345f2d283caadec9aba8c78268ff6c48711836 deleted file mode 100644 index d9a9744..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/48/345f2d283caadec9aba8c78268ff6c48711836 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/5e/76156da23b8134fbb1248d87f8af842a573002 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/5e/76156da23b8134fbb1248d87f8af842a573002 new file mode 100644 index 0000000..dd45c6d Binary files /dev/null and b/tests/test_project_fixtures/test_project_multi_commit/git/objects/5e/76156da23b8134fbb1248d87f8af842a573002 differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/7f/dd1712d35fb3950479fa65119efa83a04f41fc b/tests/test_project_fixtures/test_project_multi_commit/git/objects/7f/dd1712d35fb3950479fa65119efa83a04f41fc deleted file mode 100644 index ae05502..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/7f/dd1712d35fb3950479fa65119efa83a04f41fc and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/84/d29d064c9671c40165b0d7a852b61cc02aef50 similarity index 53% rename from tests/test_project_fixtures/test_project_add_not_null_column/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 rename to tests/test_project_fixtures/test_project_multi_commit/git/objects/84/d29d064c9671c40165b0d7a852b61cc02aef50 index 003a2f3..043f195 100644 Binary files a/tests/test_project_fixtures/test_project_add_not_null_column/git/objects/42/9e00355cee29f0d18bfcbc67555f9c8fbe0cf0 and b/tests/test_project_fixtures/test_project_multi_commit/git/objects/84/d29d064c9671c40165b0d7a852b61cc02aef50 differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/87/76fa3b34105744f98699924fbfbc5fd7f4e59f b/tests/test_project_fixtures/test_project_multi_commit/git/objects/87/76fa3b34105744f98699924fbfbc5fd7f4e59f deleted file mode 100644 index d39fd64..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/87/76fa3b34105744f98699924fbfbc5fd7f4e59f and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/a9/9fb787f53fad33eb031f8d252086c8a22c71a3 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/a9/9fb787f53fad33eb031f8d252086c8a22c71a3 deleted file mode 100644 index 35df92a..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/a9/9fb787f53fad33eb031f8d252086c8a22c71a3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/b2/4c3cadaa1bed0689b23beffe4dc11ea7220f80 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/b2/4c3cadaa1bed0689b23beffe4dc11ea7220f80 new file mode 100644 index 0000000..22e926a --- /dev/null +++ b/tests/test_project_fixtures/test_project_multi_commit/git/objects/b2/4c3cadaa1bed0689b23beffe4dc11ea7220f80 @@ -0,0 +1 @@ +x%ŒA ]sŠ¿76¼R($Ƹð®�MµÓ�··�‹—¼YÌ4?”;ÔðH±dv6h7(Ú ï#²lV#˜£²£µ,³hßW¢XK™›h[cö3¥•nþ=óé^ÃZã“μc÷ùãu*~^ºÍ¼4àœ‘t”�RìˆÆo, \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/d7/125d5f4f0cc9623f670a66c54f131acc50032d b/tests/test_project_fixtures/test_project_multi_commit/git/objects/d7/125d5f4f0cc9623f670a66c54f131acc50032d new file mode 100644 index 0000000..7634fdc Binary files /dev/null and b/tests/test_project_fixtures/test_project_multi_commit/git/objects/d7/125d5f4f0cc9623f670a66c54f131acc50032d differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/db/d8d7899446de17d8cf8e57aa7eddb1433bc9c3 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/db/d8d7899446de17d8cf8e57aa7eddb1433bc9c3 new file mode 100644 index 0000000..2dc6a73 Binary files /dev/null and b/tests/test_project_fixtures/test_project_multi_commit/git/objects/db/d8d7899446de17d8cf8e57aa7eddb1433bc9c3 differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/dc/16039b7458a98bcf9be2b92389e176ae1d9461 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/dc/16039b7458a98bcf9be2b92389e176ae1d9461 deleted file mode 100644 index 82e8dcf..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/dc/16039b7458a98bcf9be2b92389e176ae1d9461 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa b/tests/test_project_fixtures/test_project_multi_commit/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa deleted file mode 100644 index 02f7652..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/dd/a78f10740fe52637c5a7ba4d18816672c627fa and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/e5/d9d54f36eb3916eebe9ce689180572abc355f3 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/e5/d9d54f36eb3916eebe9ce689180572abc355f3 deleted file mode 100644 index e6b6c06..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/e5/d9d54f36eb3916eebe9ce689180572abc355f3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/f1/31a1ec97d003f08b920190bc152d82d850c4ca b/tests/test_project_fixtures/test_project_multi_commit/git/objects/f1/31a1ec97d003f08b920190bc152d82d850c4ca deleted file mode 100644 index 529c689..0000000 --- a/tests/test_project_fixtures/test_project_multi_commit/git/objects/f1/31a1ec97d003f08b920190bc152d82d850c4ca +++ /dev/null @@ -1,2 +0,0 @@ -x%ŒË -Â0E]ç+f/–™<ÚD\ø ‚뼩"5(þ½)]\¸gqN³HÊ]u÷èH)N£‘tÒ‰¤Æ�´™œÐ‚PIc4÷޵ß+‚¯¥Ì�µÞè£õä¸ÀÅ~æp¸U·Tÿ€cXqønxÎÅÎÏ¡›' …ò a�‘±k|·-õ<œ,Þ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/f5/39458143158b494ab979422984dfb2c280303f b/tests/test_project_fixtures/test_project_multi_commit/git/objects/f5/39458143158b494ab979422984dfb2c280303f deleted file mode 100644 index cd8c311..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/f5/39458143158b494ab979422984dfb2c280303f and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/objects/fe/961bc4402a57bace36648e1a6f1998bae3c5e3 b/tests/test_project_fixtures/test_project_multi_commit/git/objects/fe/961bc4402a57bace36648e1a6f1998bae3c5e3 deleted file mode 100644 index abb994b..0000000 Binary files a/tests/test_project_fixtures/test_project_multi_commit/git/objects/fe/961bc4402a57bace36648e1a6f1998bae3c5e3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_multi_commit/git/refs/heads/master b/tests/test_project_fixtures/test_project_multi_commit/git/refs/heads/master index fe0eab2..3add879 100644 --- a/tests/test_project_fixtures/test_project_multi_commit/git/refs/heads/master +++ b/tests/test_project_fixtures/test_project_multi_commit/git/refs/heads/master @@ -1 +1 @@ -dc16039b7458a98bcf9be2b92389e176ae1d9461 +1021d98b5943db56122c1f848f371ddc38788d0f diff --git a/tests/test_project_fixtures/test_project_rename_column/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_rename_column/git/COMMIT_EDITMSG deleted file mode 100644 index 64988b6..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/COMMIT_EDITMSG +++ /dev/null @@ -1 +0,0 @@ -All files diff --git a/tests/test_project_fixtures/test_project_rename_column/git/HEAD b/tests/test_project_fixtures/test_project_rename_column/git/HEAD deleted file mode 100644 index cb089cd..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/HEAD +++ /dev/null @@ -1 +0,0 @@ -ref: refs/heads/master diff --git a/tests/test_project_fixtures/test_project_rename_column/git/config b/tests/test_project_fixtures/test_project_rename_column/git/config deleted file mode 100644 index eeb8dd7..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/config +++ /dev/null @@ -1,5 +0,0 @@ -[core] - repositoryformatversion = 0 - filemode = false - bare = false - logallrefupdates = true diff --git a/tests/test_project_fixtures/test_project_rename_column/git/description b/tests/test_project_fixtures/test_project_rename_column/git/description deleted file mode 100644 index 498b267..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/description +++ /dev/null @@ -1 +0,0 @@ -Unnamed repository; edit this file 'description' to name the repository. diff --git a/tests/test_project_fixtures/test_project_rename_column/git/index b/tests/test_project_fixtures/test_project_rename_column/git/index deleted file mode 100644 index abae302..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/index and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/info/exclude b/tests/test_project_fixtures/test_project_rename_column/git/info/exclude deleted file mode 100644 index a5196d1..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/info/exclude +++ /dev/null @@ -1,6 +0,0 @@ -# git ls-files --others --exclude-from=.git/info/exclude -# Lines that start with '#' are comments. -# For a project mostly in C, the following would be a good set of -# exclude patterns (uncomment them if you want to use them): -# *.[oa] -# *~ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/logs/HEAD b/tests/test_project_fixtures/test_project_rename_column/git/logs/HEAD deleted file mode 100644 index e835dee..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/logs/HEAD +++ /dev/null @@ -1,2 +0,0 @@ -0000000000000000000000000000000000000000 1c81ac236b008c087902e21ef7d41a45c8ae9bf7 David-Wobrock 1509047595 +0200 commit (initial): Init -1c81ac236b008c087902e21ef7d41a45c8ae9bf7 0a898aa4fac2fd21adeabfa9a0f89df447b0b55e David-Wobrock 1509047604 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_rename_column/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_rename_column/git/logs/refs/heads/master deleted file mode 100644 index e835dee..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/logs/refs/heads/master +++ /dev/null @@ -1,2 +0,0 @@ -0000000000000000000000000000000000000000 1c81ac236b008c087902e21ef7d41a45c8ae9bf7 David-Wobrock 1509047595 +0200 commit (initial): Init -1c81ac236b008c087902e21ef7d41a45c8ae9bf7 0a898aa4fac2fd21adeabfa9a0f89df447b0b55e David-Wobrock 1509047604 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/0a/898aa4fac2fd21adeabfa9a0f89df447b0b55e b/tests/test_project_fixtures/test_project_rename_column/git/objects/0a/898aa4fac2fd21adeabfa9a0f89df447b0b55e deleted file mode 100644 index bc4a0e9..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/objects/0a/898aa4fac2fd21adeabfa9a0f89df447b0b55e +++ /dev/null @@ -1,2 +0,0 @@ -x¥ŽM -Â0F]çÙ‹e’¦ùïàz2™j°5£^ߊGpù>x��Ê<ç&uoW­2ËÁ±ë{zpHQk›È%ƒè 1õF{qÇÊ·&y…´èÀx@³V<.‚B3�GqtŸíRª<â+§Í©ÄZè*·é‹Ýû‡ûóŒyê¨Ì;©`œ#× IJ.Gÿ‘‡i’cžø!>|Jÿ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/18/4f7577a2fc2b094acc06a5a0fa10fd88bdfe93 b/tests/test_project_fixtures/test_project_rename_column/git/objects/18/4f7577a2fc2b094acc06a5a0fa10fd88bdfe93 deleted file mode 100644 index e3d8905..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/18/4f7577a2fc2b094acc06a5a0fa10fd88bdfe93 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/1c/81ac236b008c087902e21ef7d41a45c8ae9bf7 b/tests/test_project_fixtures/test_project_rename_column/git/objects/1c/81ac236b008c087902e21ef7d41a45c8ae9bf7 deleted file mode 100644 index dd6880d..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/objects/1c/81ac236b008c087902e21ef7d41a45c8ae9bf7 +++ /dev/null @@ -1 +0,0 @@ -x¥�1!E­9ÅôÆÍ,BbÌ6žÀš�Y%+’V¯/Æ#X¾Ÿ¼ÿBÉ95í~Ó*3(²RÇ`” d˜œGƒ¬Í6'­�‰Y9T¯í^*œý+ÅݵP-a�cüâðþátË>=†Pò F�Ý:h§a‹Qôµ‡ÿq!.ÏÔÄ&¦;û \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/3c/ee643962df7bfab0b21688f02af79fa19a214a b/tests/test_project_fixtures/test_project_rename_column/git/objects/3c/ee643962df7bfab0b21688f02af79fa19a214a deleted file mode 100644 index 99083d8..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/3c/ee643962df7bfab0b21688f02af79fa19a214a and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 b/tests/test_project_fixtures/test_project_rename_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 deleted file mode 100644 index adf6411..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/57/e406836937bd0e9db226dc7d4aa70dec0c3428 b/tests/test_project_fixtures/test_project_rename_column/git/objects/57/e406836937bd0e9db226dc7d4aa70dec0c3428 deleted file mode 100644 index d83b4a5..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/57/e406836937bd0e9db226dc7d4aa70dec0c3428 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/5f/183f1a90221cd21354f05d604a9bfe9aa18bd3 b/tests/test_project_fixtures/test_project_rename_column/git/objects/5f/183f1a90221cd21354f05d604a9bfe9aa18bd3 deleted file mode 100644 index 5d6ca71..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/5f/183f1a90221cd21354f05d604a9bfe9aa18bd3 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/62/bc1d2927e5023345701277baef9e0a52eb7b47 b/tests/test_project_fixtures/test_project_rename_column/git/objects/62/bc1d2927e5023345701277baef9e0a52eb7b47 deleted file mode 100644 index f5b78d2..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/62/bc1d2927e5023345701277baef9e0a52eb7b47 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 b/tests/test_project_fixtures/test_project_rename_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 deleted file mode 100644 index 3f771d5..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 b/tests/test_project_fixtures/test_project_rename_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 deleted file mode 100644 index cf19499..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 +++ /dev/null @@ -1 +0,0 @@ -xm�OOA Å=ϧhö‰îãE& Á(ÀxœvºË�Ît3S@¿½Ëžš¦¯ï÷Ú5ñîoŠ¢P_Ëé jŽ�o¡áä£`2‚YL—x‹µÀ¥–JÍð»ãŒdƒp^¶DvM6ƒ…ÀnGxG¸G‚½Mþ4Š6 ƒª²]G¾¶â9VUï÷Ú'{x8 €coî34žð2¢ÚˆtùIkÇu.ÝÖÆ–ÿ2Õ4F=*G#½áƒ°vØÿŒ¢¹õZÏT>tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_rename_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_rename_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_rename_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/90/a71dcc5ba8aef7b217bba34450fe8f0083fa6b b/tests/test_project_fixtures/test_project_rename_column/git/objects/90/a71dcc5ba8aef7b217bba34450fe8f0083fa6b deleted file mode 100644 index e91e43a..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/objects/90/a71dcc5ba8aef7b217bba34450fe8f0083fa6b +++ /dev/null @@ -1,3 +0,0 @@ -x]PËjÃ0ìÙ_±�ƒ�›(4m øRrÈ­·„m­�ZY2zÒ¯¯dåY„˜™�™U-T Ëåüaùc�b\v+p¶Í_’Là%êÊ"ƒú›¯Jv -HAHñ JÂbN^r2ÏK O+²HZ­z ´uÖi¤x?(mÁIîÍ‘ -n½›0I²Ñ¯`õY×ó·q%Í z?”I#*c`¦²«¨¸€ÓU’€?\rË+%|h‡c8 d(ŽÆŸ£ð95„íBà… 67oýúûP&'ެz,Óu:»C[Ž‚™2†Da¼³”³ô¼U±vVmƒ4«ü‹6c+Cé š÷•>Òo<žƒÚoűÜúßó’Ôµ2Hc‰Ý&�Nï{„Ð,•N:VºFï¤ÅuL‚1ãÿüájwr>$n$£$ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_rename_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/92/5381bcf8fca9f7afa84b0207362ab00ec4e378 b/tests/test_project_fixtures/test_project_rename_column/git/objects/92/5381bcf8fca9f7afa84b0207362ab00ec4e378 deleted file mode 100644 index 842d4a8..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/92/5381bcf8fca9f7afa84b0207362ab00ec4e378 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/af/f774d1a90f96c114789edd25bd37521b829233 b/tests/test_project_fixtures/test_project_rename_column/git/objects/af/f774d1a90f96c114789edd25bd37521b829233 deleted file mode 100644 index 75a2266..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/af/f774d1a90f96c114789edd25bd37521b829233 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_rename_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/e9/987576bd20e05b669a05e600a83b9afed6b0d8 b/tests/test_project_fixtures/test_project_rename_column/git/objects/e9/987576bd20e05b669a05e600a83b9afed6b0d8 deleted file mode 100644 index 133a77a..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/e9/987576bd20e05b669a05e600a83b9afed6b0d8 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 b/tests/test_project_fixtures/test_project_rename_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 deleted file mode 100644 index a0339be..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_column/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_column/git/refs/heads/master b/tests/test_project_fixtures/test_project_rename_column/git/refs/heads/master deleted file mode 100644 index 5b17443..0000000 --- a/tests/test_project_fixtures/test_project_rename_column/git/refs/heads/master +++ /dev/null @@ -1 +0,0 @@ -0a898aa4fac2fd21adeabfa9a0f89df447b0b55e diff --git a/tests/test_project_fixtures/test_project_rename_table/git/COMMIT_EDITMSG b/tests/test_project_fixtures/test_project_rename_table/git/COMMIT_EDITMSG deleted file mode 100644 index 64988b6..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/COMMIT_EDITMSG +++ /dev/null @@ -1 +0,0 @@ -All files diff --git a/tests/test_project_fixtures/test_project_rename_table/git/HEAD b/tests/test_project_fixtures/test_project_rename_table/git/HEAD deleted file mode 100644 index cb089cd..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/HEAD +++ /dev/null @@ -1 +0,0 @@ -ref: refs/heads/master diff --git a/tests/test_project_fixtures/test_project_rename_table/git/config b/tests/test_project_fixtures/test_project_rename_table/git/config deleted file mode 100644 index eeb8dd7..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/config +++ /dev/null @@ -1,5 +0,0 @@ -[core] - repositoryformatversion = 0 - filemode = false - bare = false - logallrefupdates = true diff --git a/tests/test_project_fixtures/test_project_rename_table/git/description b/tests/test_project_fixtures/test_project_rename_table/git/description deleted file mode 100644 index 498b267..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/description +++ /dev/null @@ -1 +0,0 @@ -Unnamed repository; edit this file 'description' to name the repository. diff --git a/tests/test_project_fixtures/test_project_rename_table/git/index b/tests/test_project_fixtures/test_project_rename_table/git/index deleted file mode 100644 index c9d7645..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/index and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/info/exclude b/tests/test_project_fixtures/test_project_rename_table/git/info/exclude deleted file mode 100644 index a5196d1..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/info/exclude +++ /dev/null @@ -1,6 +0,0 @@ -# git ls-files --others --exclude-from=.git/info/exclude -# Lines that start with '#' are comments. -# For a project mostly in C, the following would be a good set of -# exclude patterns (uncomment them if you want to use them): -# *.[oa] -# *~ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/logs/HEAD b/tests/test_project_fixtures/test_project_rename_table/git/logs/HEAD deleted file mode 100644 index c50678d..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/logs/HEAD +++ /dev/null @@ -1,2 +0,0 @@ -0000000000000000000000000000000000000000 bdc56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa David-Wobrock 1509047712 +0200 commit (initial): Init -bdc56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa cd1aa87abf1095d2ca6b9b64308931ab52e598c8 David-Wobrock 1509047722 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_rename_table/git/logs/refs/heads/master b/tests/test_project_fixtures/test_project_rename_table/git/logs/refs/heads/master deleted file mode 100644 index c50678d..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/logs/refs/heads/master +++ /dev/null @@ -1,2 +0,0 @@ -0000000000000000000000000000000000000000 bdc56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa David-Wobrock 1509047712 +0200 commit (initial): Init -bdc56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa cd1aa87abf1095d2ca6b9b64308931ab52e598c8 David-Wobrock 1509047722 +0200 commit: All files diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/26/33c5502148ad76d39331a6f075cbc2aa3413ba b/tests/test_project_fixtures/test_project_rename_table/git/objects/26/33c5502148ad76d39331a6f075cbc2aa3413ba deleted file mode 100644 index 82bf546..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/26/33c5502148ad76d39331a6f075cbc2aa3413ba and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 b/tests/test_project_fixtures/test_project_rename_table/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 deleted file mode 100644 index adf6411..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/4b/825dc642cb6eb9a060e54bf8d69288fbee4904 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 b/tests/test_project_fixtures/test_project_rename_table/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 deleted file mode 100644 index 3f771d5..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/63/973d01988ba594743a8046c9c88c2aa527d307 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 b/tests/test_project_fixtures/test_project_rename_table/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 deleted file mode 100644 index cf19499..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/objects/67/41b31d80b759d26496e68078ea8c6993a5b206 +++ /dev/null @@ -1 +0,0 @@ -xm�OOA Å=ϧhö‰îãE& Á(ÀxœvºË�Ît3S@¿½Ëžš¦¯ï÷Ú5ñîoŠ¢P_Ëé jŽ�o¡áä£`2‚YL—x‹µÀ¥–JÍð»ãŒdƒp^¶DvM6ƒ…ÀnGxG¸G‚½Mþ4Š6 ƒª²]G¾¶â9VUï÷Ú'{x8 €coî34žð2¢ÚˆtùIkÇu.ÝÖÆ–ÿ2Õ4F=*G#½áƒ°vØÿŒ¢¹õZÏT>tœ8+Õ$pv)ë^ep´(æØ›«¨Jq.1î}âXf‡�Ý‘ ŠñÛË|º0ËÉj5›O—æc1þ|Ÿ·P\ÿÏXçLd1qGdj¦]8Ùˆ�m.†J]¡àþK0ª_òCš€ \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/71/6d88c3f72dfc3e2d9d97f861c19ba2318c9ef5 b/tests/test_project_fixtures/test_project_rename_table/git/objects/71/6d88c3f72dfc3e2d9d97f861c19ba2318c9ef5 deleted file mode 100644 index 76af696..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/71/6d88c3f72dfc3e2d9d97f861c19ba2318c9ef5 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee b/tests/test_project_fixtures/test_project_rename_table/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee deleted file mode 100644 index 66ccc09..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/73/5de5db8bc5e1ed29b3cb7ece62b5e7c8db06ee and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 b/tests/test_project_fixtures/test_project_rename_table/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 deleted file mode 100644 index 250bef6..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/7c/e503c2dd97ba78597f6ff6e4393132753573f6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/7f/c9a68ff524659a2182df44137c56335a1d80b6 b/tests/test_project_fixtures/test_project_rename_table/git/objects/7f/c9a68ff524659a2182df44137c56335a1d80b6 deleted file mode 100644 index 2c43bef..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/7f/c9a68ff524659a2182df44137c56335a1d80b6 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/86/e18cb66dc015f7c74d4d125ca9b814485e5ae4 b/tests/test_project_fixtures/test_project_rename_table/git/objects/86/e18cb66dc015f7c74d4d125ca9b814485e5ae4 deleted file mode 100644 index 06a24f0..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/86/e18cb66dc015f7c74d4d125ca9b814485e5ae4 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e b/tests/test_project_fixtures/test_project_rename_table/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e deleted file mode 100644 index e68f806..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/8c/38f3f3dad51e4585f3984282c2a4bec5349c1e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/91/ea44a218fbd2f408430959283f0419c921093e b/tests/test_project_fixtures/test_project_rename_table/git/objects/91/ea44a218fbd2f408430959283f0419c921093e deleted file mode 100644 index 263fc8c..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/91/ea44a218fbd2f408430959283f0419c921093e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/92/a21e6d935deaba88f676457f189e9c9c2a75bb b/tests/test_project_fixtures/test_project_rename_table/git/objects/92/a21e6d935deaba88f676457f189e9c9c2a75bb deleted file mode 100644 index 76f1a71..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/92/a21e6d935deaba88f676457f189e9c9c2a75bb and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/bd/c56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa b/tests/test_project_fixtures/test_project_rename_table/git/objects/bd/c56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa deleted file mode 100644 index 03b4008..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/objects/bd/c56b5a08fe5d060b09bcc9a54cf5d9c8b88dfa +++ /dev/null @@ -1 +0,0 @@ -x¥�1B!­9ÅöÆŸ�‰16žÀš…ýJIêõÅxËyɼ‰µ”ÜAºíª7fÐä”IÑjÉ2ù€ÙhZ\²^9·³ö¨Exökmp ¯œ6çJ­ÆìÒ§÷—ò}еìAÖ#G;é \ No newline at end of file diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/cd/1aa87abf1095d2ca6b9b64308931ab52e598c8 b/tests/test_project_fixtures/test_project_rename_table/git/objects/cd/1aa87abf1095d2ca6b9b64308931ab52e598c8 deleted file mode 100644 index e08128c..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/cd/1aa87abf1095d2ca6b9b64308931ab52e598c8 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/d8/47af6cf50a2587894a4fcb8a712e411adaaefd b/tests/test_project_fixtures/test_project_rename_table/git/objects/d8/47af6cf50a2587894a4fcb8a712e411adaaefd deleted file mode 100644 index 93b09f8..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/d8/47af6cf50a2587894a4fcb8a712e411adaaefd and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/de/e3fd6ea2c3257f15eed8ba7608f5ea9b20062e b/tests/test_project_fixtures/test_project_rename_table/git/objects/de/e3fd6ea2c3257f15eed8ba7608f5ea9b20062e deleted file mode 100644 index 074d608..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/de/e3fd6ea2c3257f15eed8ba7608f5ea9b20062e and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 b/tests/test_project_fixtures/test_project_rename_table/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 deleted file mode 100644 index 7112238..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/2b890b4369aabb6e396db4ed71c857e72dd7de b/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/2b890b4369aabb6e396db4ed71c857e72dd7de deleted file mode 100644 index 58dff70..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/2b890b4369aabb6e396db4ed71c857e72dd7de and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/5ea5c1a969f7e950efb86deadd0a4e4fe1a256 b/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/5ea5c1a969f7e950efb86deadd0a4e4fe1a256 deleted file mode 100644 index bd4ba1a..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/f7/5ea5c1a969f7e950efb86deadd0a4e4fe1a256 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 b/tests/test_project_fixtures/test_project_rename_table/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 deleted file mode 100644 index a0339be..0000000 Binary files a/tests/test_project_fixtures/test_project_rename_table/git/objects/fc/04070e8336f17e3b2402586653623e6bb51f67 and /dev/null differ diff --git a/tests/test_project_fixtures/test_project_rename_table/git/refs/heads/master b/tests/test_project_fixtures/test_project_rename_table/git/refs/heads/master deleted file mode 100644 index b95031a..0000000 --- a/tests/test_project_fixtures/test_project_rename_table/git/refs/heads/master +++ /dev/null @@ -1 +0,0 @@ -cd1aa87abf1095d2ca6b9b64308931ab52e598c8 diff --git a/tests/unit/test_linter.py b/tests/unit/test_linter.py new file mode 100644 index 0000000..b658d93 --- /dev/null +++ b/tests/unit/test_linter.py @@ -0,0 +1,107 @@ +# Copyright 2017 3YOURMIND GmbH + +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at + +# http://www.apache.org/licenses/LICENSE-2.0 + +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +import unittest + +from django_migration_linter import MigrationLinter +from tests import fixtures + + +class TestLinterFunctions(unittest.TestCase): + def test_get_sql(self): + project_path = fixtures.ADD_NOT_NULL_COLUMN_PROJECT + linter = MigrationLinter(project_path) + sql_statements = linter.get_sql('test_app', '0001') + self.assertEqual(len(sql_statements), 6) + self.assertEqual(sql_statements[0], 'BEGIN;') + self.assertEqual(sql_statements[-1], 'COMMIT;') + + def test_has_errors(self): + project_path = fixtures.MULTI_COMMIT_PROJECT + linter = MigrationLinter(project_path) + self.assertFalse(linter.has_errors) + + linter.lint_migration('test_app', '0001') + self.assertFalse(linter.has_errors) + + linter.lint_migration('test_app', '0002') + self.assertTrue(linter.has_errors) + + linter.lint_migration('test_app', '0001') + self.assertTrue(linter.has_errors) + + def test_linter_creation(self): + with self.assertRaises(ValueError): + MigrationLinter('foo/') + with self.assertRaises(ValueError): + MigrationLinter('/dev/null') + with self.assertRaises(ValueError): + MigrationLinter(fixtures.NOT_DJANGO_GIT_PROJECT) + + def test_split_migration_long_path(self): + input_path = 'apps/the_app/migrations/0001_stuff.py' + app, mig = MigrationLinter._split_migration_path(input_path) + self.assertEqual(app, 'the_app') + self.assertEqual(mig, '0001_stuff') + + def test_split_migration_path(self): + input_path = 'the_app/migrations/0001_stuff.py' + app, mig = MigrationLinter._split_migration_path(input_path) + self.assertEqual(app, 'the_app') + self.assertEqual(mig, '0001_stuff') + + def test_split_migration_full_path(self): + input_path = '/home/user/djangostuff/apps/the_app/migrations/0001_stuff.py' + app, mig = MigrationLinter._split_migration_path(input_path) + self.assertEqual(app, 'the_app') + self.assertEqual(mig, '0001_stuff') + + def test_ignore_migration_include_apps(self): + linter = MigrationLinter( + fixtures.ADD_NOT_NULL_COLUMN_PROJECT, + include_apps=('test_app2',)) + self.assertTrue(linter.should_ignore_migration('test_app1', '0001')) + self.assertFalse(linter.should_ignore_migration('test_app2', '0001')) + + def test_ignore_migration_exclude_apps(self): + linter = MigrationLinter( + fixtures.ADD_NOT_NULL_COLUMN_PROJECT, + exclude_apps=('test_app1',)) + self.assertTrue(linter.should_ignore_migration('test_app1', '0001')) + self.assertFalse(linter.should_ignore_migration('test_app2', '0001')) + + def test_ignore_migration_name_contains(self): + linter = MigrationLinter( + fixtures.ADD_NOT_NULL_COLUMN_PROJECT, + ignore_name_contains='foo') + self.assertTrue(linter.should_ignore_migration('test_app', '0001_foo')) + self.assertFalse(linter.should_ignore_migration('test_app', '0002_bar')) + + def test_ignore_migration_full_name(self): + linter = MigrationLinter( + fixtures.ADD_NOT_NULL_COLUMN_PROJECT, + ignore_name=('0001_foo',)) + self.assertTrue(linter.should_ignore_migration('test_app', '0001_foo')) + self.assertFalse(linter.should_ignore_migration('test_app', '0002_bar')) + + def test_gather_all_migrations(self): + linter = MigrationLinter(fixtures.CORRECT_PROJECT) + migrations = linter._gather_all_migrations() + self.assertEqual(len(migrations), 3) + self.assertEqual(migrations[0][0], 'test_app1') + self.assertEqual(migrations[0][1], '0001_initial') + self.assertEqual(migrations[1][0], 'test_app1') + self.assertEqual(migrations[1][1], '0002_a_new_null_field') + self.assertEqual(migrations[2][0], 'test_app2') + self.assertEqual(migrations[2][1], '0001_foo') diff --git a/tests/unit/test_utils.py b/tests/unit/test_utils.py index 151f48b..fd6d5d0 100644 --- a/tests/unit/test_utils.py +++ b/tests/unit/test_utils.py @@ -12,40 +12,61 @@ # See the License for the specific language governing permissions and # limitations under the License. +import os import unittest from tests import fixtures -from django_migration_linter import MigrationLinter, valid_folder +from django_migration_linter.utils import is_django_project, is_git_project, is_directory, find_project_settings_module, split_path class UtilityFunctionTest(unittest.TestCase): def tearDown(self, *args, **kwargs): - #fixtures.clear_all_git_projects() + fixtures.clear_all_git_projects() super( UtilityFunctionTest, self).tearDown(*args, **kwargs) - def test_split_migration_path(self): - input_path = 'apps/the_app/migrations/0001_stuff.py' - app, mig = MigrationLinter._split_migration_path(input_path) - self.assertEqual(app, 'the_app') - self.assertEqual(mig, '0001_stuff') + def test_detect_not_git_project(self): + self.assertFalse(is_git_project(fixtures.NOT_GIT_DJANGO_PROJECT)) - def test_split_migration_path_2(self): - input_path = 'the_app/migrations/0001_stuff.py' - app, mig = MigrationLinter._split_migration_path(input_path) - self.assertEqual(app, 'the_app') - self.assertEqual(mig, '0001_stuff') + def test_detect_git_project(self): + project_path = fixtures.MULTI_COMMIT_PROJECT + fixtures.prepare_git_project(project_path) + self.assertTrue(is_git_project(project_path)) - def test_detect_valid_folder(self): - test_project_path = fixtures.MULTI_COMMIT_PROJECT - fixtures.prepare_git_project(test_project_path) - self.assertTrue(valid_folder(test_project_path)) + def test_detect_django_project(self): + self.assertTrue(is_django_project(fixtures.ADD_NOT_NULL_COLUMN_PROJECT)) def test_detect_not_django_project(self): - test_project_path = fixtures.NOT_DJANGO_GIT_PROJECT - fixtures.prepare_git_project(test_project_path) - self.assertFalse(valid_folder(test_project_path)) + self.assertFalse(is_django_project(fixtures._BASE_DIR)) - def test_detect_not_git_project(self): - self.assertFalse(valid_folder(fixtures.NOT_GIT_DJANGO_PROJECT)) + def test_detect_directory(self): + self.assertTrue(is_directory(fixtures.ADD_NOT_NULL_COLUMN_PROJECT)) + + def test_detect_not_directory(self): + self.assertFalse(is_directory( + os.path.join(fixtures.ADD_NOT_NULL_COLUMN_PROJECT, 'manage.py'))) + + def test_find_project_settings_module_same_project_name(self): + expected = 'test_project_add_not_null_column.settings' + actual = find_project_settings_module(fixtures.ADD_NOT_NULL_COLUMN_PROJECT) + self.assertEqual(actual, expected) + + def test_find_project_settings_module_different_project_name(self): + expected = 'test_project.settings' + actual = find_project_settings_module(fixtures.CORRECT_PROJECT) + self.assertEqual(actual, expected) + + def test_split_path(self): + splitted = split_path('foo/bar/fuz.py') + self.assertEqual(len(splitted), 3) + self.assertEqual(splitted[0], 'foo') + self.assertEqual(splitted[1], 'bar') + self.assertEqual(splitted[2], 'fuz.py') + + def test_split_full_path(self): + splitted = split_path('/foo/bar/fuz.py') + self.assertEqual(len(splitted), 3) + self.assertEqual(splitted[0], 'foo') + self.assertEqual(splitted[1], 'bar') + self.assertEqual(splitted[2], 'fuz.py')