[ckan-dev] Running tests that rely on a background job
Nevelina Aleksandrova
nevelina.aleksandrova at gmail.com
Thu Feb 1 14:21:49 UTC 2018
Many thanks for the pointers Florian, worked a treat! We ended up moving
the mock wrapper into a decorator to remove the concern from the tests
themselves.
https://github.com/CottageLabs/ckanext-string_to_location/blob/master/ckanext/string_to_location/tests/rq_test_helpers.py
Best,
Nevelina
On 30 Jan 2018 16:09, "Nevelina Aleksandrova" <
nevelina.aleksandrova at gmail.com> wrote:
> Hello,
>
> We have been working on a plugin for CKAN that takes a column in a
> spreadsheet which signifies a location name (e.g. Birmingham) and maps that
> to a geo polygon. We're at the point where we have refactored the mapping
> into a background job and consequently our end-to-end tests are failing.
>
> I was wondering if you had any advice on how to execute RQ background jobs
> inline in tests?
>
> The plugin is located here https://github.com/
> CottageLabs/ckanext-string_to_location, we're using CKAN 2.7.2.
>
> Any pointers are much appreciated.
>
> Thanks,
> Nevelina
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20180201/139c556a/attachment-0002.html>
More information about the ckan-dev
mailing list