Move db/util.py -> db/mongo/util.py
[mediagoblin.git] / mediagoblin / tests / test_celery_setup.py
index 33c50e40475e40a33f2fe6bc2d8e4e575c609ffe..19a9b899de917d0a32ac3e46194aeb21f60d42a7 100644 (file)
@@ -1,5 +1,5 @@
 # GNU MediaGoblin -- federated, autonomous media hosting
-# Copyright (C) 2011 Free Software Foundation, Inc
+# Copyright (C) 2011 MediaGoblin contributors.  See AUTHORS.
 #
 # This program is free software: you can redistribute it and/or modify
 # it under the terms of the GNU Affero General Public License as published by
 # You should have received a copy of the GNU Affero General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-from mediagoblin import celery_setup
-from mediagoblin.config import read_mediagoblin_config
+import pkg_resources
+
+from mediagoblin.init import celery as celery_setup
+from mediagoblin.init.config import read_mediagoblin_config
 
 
 TEST_CELERY_CONF_NOSPECIALDB = pkg_resources.resource_filename(
@@ -48,7 +50,7 @@ def test_setup_celery_from_config():
     assert isinstance(fake_celery_module.CELERYD_ETA_SCHEDULER_PRECISION, float)
     assert fake_celery_module.CELERY_RESULT_PERSISTENT is True
     assert fake_celery_module.CELERY_IMPORTS == [
-        'foo.bar.baz', 'this.is.an.import', 'mediagoblin.process_media']
+        'foo.bar.baz', 'this.is.an.import', 'mediagoblin.processing']
     assert fake_celery_module.CELERY_MONGODB_BACKEND_SETTINGS == {
         'database': 'mediagoblin'}
     assert fake_celery_module.CELERY_RESULT_BACKEND == 'mongodb'
@@ -72,7 +74,7 @@ def test_setup_celery_from_config():
     assert isinstance(fake_celery_module.CELERYD_ETA_SCHEDULER_PRECISION, float)
     assert fake_celery_module.CELERY_RESULT_PERSISTENT is False
     assert fake_celery_module.CELERY_IMPORTS == [
-        'baz.bar.foo', 'import.is.a.this', 'mediagoblin.process_media']
+        'baz.bar.foo', 'import.is.a.this', 'mediagoblin.processing']
     assert fake_celery_module.CELERY_MONGODB_BACKEND_SETTINGS == {
         'database': 'captain_lollerskates',
         'host': 'mongodb.example.org',