Commit Graph

176 Commits

Author SHA1 Message Date
amercader c87309a8dc Remove pyopenssl requirement 2022-10-11 15:30:31 +02:00
amercader 7b6097ad98 Cross-version mock import 2022-07-14 14:00:52 +02:00
amercader b92b364bd9 Refactor tests to avoid failures
Caused by https://github.com/ckan/ckan/issues/6880
2022-07-14 14:00:13 +02:00
cirun 2ce1164744 fix for test_blueprint.py 2022-04-12 23:01:30 +02:00
amercader e8362c4616 Use unicode_safe validator in schema
CKAN core no longer supports builtin functions as validators.
Requires ckantoolkit>=0.0.7 for CKAN 2.7 support
2022-04-08 14:40:20 +02:00
seitenbau-govdata d2b7340509 Rename keep-actual to keep-current and updated documentation 2021-12-22 10:39:18 +01:00
seitenbau-govdata 6b238f8d74 Add option keep-actual to clearsource_history command 2021-12-18 22:29:25 +01:00
seitenbau-govdata d2cf517f88 Clears redis db before queue test
Makes the test independent of the test execution order
Prevents the test from failing on a server that is not freshly installed
2021-11-22 11:10:45 +01:00
seitenbau-govdata 0a06cad506 Adds test for queue.resubmit_objects() 2021-11-20 11:38:20 +01:00
jbrown-xentity a418ed4a8b Remove unnecessary code, add tests 2021-10-04 14:41:41 -06:00
James Brown b3b519ad31
Revert "Fix pkg extras" 2021-09-30 11:07:31 -06:00
jbrown-xentity d06444e409 Add harvest info to solr
This allows the harvest information on the package to be easily searched
and removes complicated logic for adding/removing extras
2021-09-20 12:02:35 -06:00
Jari Voutilainen 2f1a2d3689 flake8 2021-03-05 08:59:53 +02:00
Jari Voutilainen 078077c456 flake8 2021-03-05 08:49:10 +02:00
Andres Vazquez eb246439c6 Fix last harvest time to avoid timeouts 2021-02-03 11:29:07 -03:00
amercader edccfc4de0 Fix flaky redis test 2020-12-11 15:06:02 +01:00
Andres Vazquez 39db3f89d7 Improve job times 2020-10-02 11:19:35 -03:00
Andres Vazquez 13a0525e3a Improve timeouts and add tests 2020-10-02 10:44:57 -03:00
amercader 7ba9c6c6c1 Merge branch 'abort-failed-jobs-cli-command' of https://github.com/mutantsan/ckanext-harvest into mutantsan-abort-failed-jobs-cli-command 2020-09-01 11:28:26 +02:00
amercader 6c78efcb6b Fix tests, improve Travis setup
* Run pytest tests only
* Fix py2/py3 compat issues, factoryboy definitions
* Run tests on focal
* Use latest supported pg version for each ckan version
* Use dockerized Solr
2020-08-31 21:02:35 +02:00
kentsanggds 07083fe323
Merge pull request #15 from alphagov/harvest-timeout
Add timeout to harvest job
2020-06-03 16:55:49 +01:00
Ken Tsang 3cb2ac831c Set harvest objs for job to error if job aborted 2020-06-03 16:21:23 +01:00
Ken Tsang 3619dbc0ad Set job to finished if job is longer than timeout 2020-06-03 16:20:36 +01:00
Peter Hartshorn fa5987625c Allow filtering by organisation for harvest_source_list
This commit allows users of the harvest_source_list endpoint to
return harvest sources by a specific organisation by using a query param
`organization_id`. Also this endpoint won't
return more than 100 harvest sources as we were having timing out issues
due to the amount being previously returned (500+).

I've also removed the check_access method as this currently wasn't doing
anything as you didn't need to be authorized to access this endpoint.

Trello:
https://trello.com/c/iAWEYNOv/1946-5-dgu-add-ability-for-harvestsourcelist-to-filter-by-organisation%F0%9F%8D%90

Zendesk:
https://govuk.zendesk.com/agent/tickets/4034244
2020-06-01 13:36:39 +01:00
calexandr 19b737fa5b fix tests problems 2020-03-26 15:45:50 +02:00
calexandr 556136d71d write pytests 2020-03-26 15:27:58 +02:00
calexandr 6c70200a6e write nose tests 2020-03-26 15:27:51 +02:00
Ken Tsang 1ee4a58e33 Add job show object
Showing the harvest object to the user was failing as object_show_view in utils was returning a tuple rather than the harvest object.

This test added shows that the path is now working as expected.
2020-03-23 15:57:12 +00:00
amercader 345a67336d Py3 fixes, mostly bytes/str ones 2020-02-17 13:24:57 +01:00
amercader 5a0a2eb6a5 Use py3 libraries 2020-02-17 12:48:18 +01:00
amercader d2d5c34395 Second batch of pytest tests 2020-02-14 23:29:47 +01:00
amercader 16d85737fd First nose tests (again) 2020-02-14 16:01:48 +01:00
amercader d89815d664 Re-add deleted old nose tests 2020-02-14 13:54:27 +01:00
amercader caa2c71526 Fix bad merge 2020-02-14 13:49:25 +01:00
amercader 8899f67577 Merge branch 'py3-support' of github.com:ckan/ckanext-harvest into py3-support 2020-02-10 23:48:14 +01:00
amercader 88f86b5820 Pytest tests, first batch 2020-02-10 23:45:53 +01:00
amercader 1b120da59a Fix asserts 2020-02-10 22:11:42 +01:00
amercader b670aa64a8 Start splitting tests, fix nose ones 2020-02-08 01:18:20 +01:00
amercader fa81efe2a4 Merge branch 'py3' of https://github.com/DataShades/ckanext-harvest into DataShades-py3 2020-02-07 15:24:02 +01:00
Sergey Motornyuk aae1267315 Futurize. 1st stage 2020-01-15 17:33:05 +02:00
Sergey Motornyuk 55bd3fc282 Start updating cli 2020-01-15 17:32:30 +02:00
Ken Tsang 5507adc825 import mock.patch 2019-12-17 23:35:41 +00:00
kentsanggds 5fc035aa2d
Merge branch 'master' into dgu-fixes 2019-12-17 23:22:31 +00:00
Stefanie Taepke 27fbd0caad add test for error mail when HarvestObjectError occurs 2019-11-14 16:01:00 +01:00
amercader 7b251f0e3b Actually skip the log tests 2019-11-01 16:41:44 +01:00
amercader ba9a870eb9 [#369] Disable harvest db log in tests as it causes recursion problems 2019-11-01 16:31:44 +01:00
amercader 12196268d8 Merge branch 'master' into 369-broken-tests 2019-10-18 14:40:12 +02:00
amercader 3793480a91 Fix Flake8 warnings 2019-10-03 11:50:15 +02:00
amercader 18e8f5ce13 Merge branch 'master' into 369-broken-tests 2019-08-23 14:40:50 +02:00
amercader a8b1b211e1 [#369] [#369] Remove dodgy patching 2019-08-23 14:21:24 +02:00