When running tests in Django applications that make use of Celery tasks I can\'t fully test tasks that need to get data from the database since they don\'t connect to the te
A simple solution is to use celery.contrib.testing.worker.start_worker to spawn a Celery worker within the Django test process. Because it lives in the same process, it can access the default in-memory test database, but because it lives in its own thread, it isn't eager and the task_always_eager flag is not needed or recommended.