A pytest plugin to help writing unit test for django-rq
A pytest plugin to help writing unit test for django-rq.
This plugin provides a
django_rq_worker fixture which has a
to run all enqueued jobs in current process.
def test_async_api(django_rq_worker): client = django.test.Client() # Call an async API response = client.post(URL) assert response.status_code == 201 # Accepted # now let's run all enqueued jobs django_rq_worker.work() # assert the async jobs has taken place. assert ...
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for pytest_django_rq-0.2.0-py3-none-any.whl