From faf74067dae0f6f9d200a30369e9b7a4501b66ab Mon Sep 17 00:00:00 2001 From: Elrond Date: Tue, 20 Dec 2011 20:33:33 +0100 Subject: [PATCH] Move db/migrations.py -> db/mongo/migrations.py And change references. --- mediagoblin/db/models.py | 2 +- mediagoblin/db/{ => mongo}/migrations.py | 0 mediagoblin/init/__init__.py | 2 +- mediagoblin/tests/test_migrations.py | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) rename mediagoblin/db/{ => mongo}/migrations.py (100%) diff --git a/mediagoblin/db/models.py b/mediagoblin/db/models.py index 51c6e98e..e2ac1b5a 100644 --- a/mediagoblin/db/models.py +++ b/mediagoblin/db/models.py @@ -21,7 +21,7 @@ from mongokit import Document from mediagoblin.auth import lib as auth_lib from mediagoblin import mg_globals -from mediagoblin.db import migrations +from mediagoblin.db.mongo import migrations from mediagoblin.db.mongo.util import ASCENDING, DESCENDING, ObjectId from mediagoblin.tools.pagination import Pagination from mediagoblin.tools import url, common diff --git a/mediagoblin/db/migrations.py b/mediagoblin/db/mongo/migrations.py similarity index 100% rename from mediagoblin/db/migrations.py rename to mediagoblin/db/mongo/migrations.py diff --git a/mediagoblin/init/__init__.py b/mediagoblin/init/__init__.py index 08a0618d..5f7f83d4 100644 --- a/mediagoblin/init/__init__.py +++ b/mediagoblin/init/__init__.py @@ -57,7 +57,7 @@ def setup_database(): app_config = mg_globals.app_config # This MUST be imported so as to set up the appropriate migrations! - from mediagoblin.db import migrations + from mediagoblin.db.mongo import migrations # Set up the database connection, db = setup_connection_and_db_from_config(app_config) diff --git a/mediagoblin/tests/test_migrations.py b/mediagoblin/tests/test_migrations.py index 3e2e37ee..8e573f5a 100644 --- a/mediagoblin/tests/test_migrations.py +++ b/mediagoblin/tests/test_migrations.py @@ -23,7 +23,7 @@ from mediagoblin.tests.tools import ( from mediagoblin.db.mongo.util import ( RegisterMigration, MigrationManager, ObjectId, MissingCurrentMigration) -from mediagoblin.db.migrations import add_table_field +from mediagoblin.db.mongo.migrations import add_table_field # This one will get filled with local migrations TEST_MIGRATION_REGISTRY = {} -- 2.25.1