diff --git a/README.md b/README.md index d1f8a59d75..31fb9cfd00 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ addon | version | maintainers | summary --- | --- | --- | --- [base_export_async](base_export_async/) | 16.0.1.0.0 | | Asynchronous export with job queue [base_import_async](base_import_async/) | 16.0.1.1.0 | | Import CSV files in the background -[queue_job](queue_job/) | 16.0.2.6.0 | [![guewen](https://github.com/guewen.png?size=30px)](https://github.com/guewen) | Job Queue +[queue_job](queue_job/) | 16.0.2.6.1 | [![guewen](https://github.com/guewen.png?size=30px)](https://github.com/guewen) | Job Queue [queue_job_batch](queue_job_batch/) | 16.0.1.0.0 | | Job Queue Batch [queue_job_cron](queue_job_cron/) | 16.0.2.0.0 | | Scheduled Actions as Queue Jobs [queue_job_cron_jobrunner](queue_job_cron_jobrunner/) | 16.0.1.0.0 | [![ivantodorovich](https://github.com/ivantodorovich.png?size=30px)](https://github.com/ivantodorovich) | Run jobs without a dedicated JobRunner diff --git a/queue_job/README.rst b/queue_job/README.rst index 555a7e29cd..b8fafdd927 100644 --- a/queue_job/README.rst +++ b/queue_job/README.rst @@ -7,7 +7,7 @@ Job Queue !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:95c2a952bac3dd81faf83d38d12164b3b4ab09b93cbf1c108b9d59cf16b5a57e + !! source digest: sha256:3a725c71cd3c1b8ba0045e1e5e242652eb15c9146a15a3ff970c7e267ba86f9a !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Mature-brightgreen.png @@ -438,6 +438,12 @@ tests), and it makes tests smaller. The best way to run such assertions on the enqueued jobs is to use ``odoo.addons.queue_job.tests.common.trap_jobs()``. +Inside this context manager, instead of being added in the database's queue, +jobs are pushed in an in-memory list. The context manager then provides useful +helpers to verify that jobs have been enqueued with the expected arguments. It +even can run the jobs of its list synchronously! Details in +``odoo.addons.queue_job.tests.common.JobsTester``. + A very small example (more details in ``tests/common.py``): .. code-block:: python diff --git a/queue_job/static/description/index.html b/queue_job/static/description/index.html index 09c3f7e0ba..82fc29c222 100644 --- a/queue_job/static/description/index.html +++ b/queue_job/static/description/index.html @@ -366,7 +366,7 @@
This addon adds an integrated Job Queue to Odoo.
@@ -744,6 +744,11 @@The best way to run such assertions on the enqueued jobs is to use odoo.addons.queue_job.tests.common.trap_jobs().
+Inside this context manager, instead of being added in the database’s queue, +jobs are pushed in an in-memory list. The context manager then provides useful +helpers to verify that jobs have been enqueued with the expected arguments. It +even can run the jobs of its list synchronously! Details in +odoo.addons.queue_job.tests.common.JobsTester.
A very small example (more details in tests/common.py):
# code