|
@@ -37,7 +37,7 @@ from celery.utils.objects import Bunch
|
|
|
THIS_IS_A_KEY = 'this is a value'
|
|
|
|
|
|
|
|
|
-class ObjectConfig(object):
|
|
|
+class ObjectConfig:
|
|
|
FOO = 1
|
|
|
BAR = 2
|
|
|
|
|
@@ -45,7 +45,7 @@ object_config = ObjectConfig()
|
|
|
dict_config = dict(FOO=10, BAR=20)
|
|
|
|
|
|
|
|
|
-class ObjectConfig2(object):
|
|
|
+class ObjectConfig2:
|
|
|
LEAVE_FOR_WORK = True
|
|
|
MOMENT_TO_STOP = True
|
|
|
CALL_ME_BACK = 123456789
|
|
@@ -542,7 +542,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__compat(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
CELERY_ALWAYS_EAGER = 44
|
|
|
CELERY_DEFAULT_DELIVERY_MODE = 30
|
|
|
CELERY_TASK_PUBLISH_RETRY = False
|
|
@@ -555,7 +555,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__supports_old_names(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
task_always_eager = 45
|
|
|
task_default_delivery_mode = 301
|
|
|
|
|
@@ -568,7 +568,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__namespace_uppercase(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
CELERY_TASK_ALWAYS_EAGER = 44
|
|
|
CELERY_TASK_DEFAULT_DELIVERY_MODE = 301
|
|
|
|
|
@@ -577,7 +577,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__namespace_lowercase(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
celery_task_always_eager = 44
|
|
|
celery_task_default_delivery_mode = 301
|
|
|
|
|
@@ -586,7 +586,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__mixing_new_and_old(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
task_always_eager = 44
|
|
|
worker_agent = 'foo:Agent'
|
|
|
worker_consumer = 'foo:Consumer'
|
|
@@ -601,7 +601,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_config_from_object__mixing_old_and_new(self):
|
|
|
|
|
|
- class Config(object):
|
|
|
+ class Config:
|
|
|
CELERY_ALWAYS_EAGER = 46
|
|
|
CELERYD_AGENT = 'foo:Agent'
|
|
|
CELERYD_CONSUMER = 'foo:Consumer'
|
|
@@ -851,7 +851,7 @@ class test_App(AppCase):
|
|
|
|
|
|
def test_send_task_sent_event(self):
|
|
|
|
|
|
- class Dispatcher(object):
|
|
|
+ class Dispatcher:
|
|
|
sent = []
|
|
|
|
|
|
def publish(self, type, fields, *args, **kwargs):
|