Add a 'scheduler' pytest fixture that created a scheduler usable for tests
which uses the pytest-postgresql package to manage the database life cycle.
Also remove now useless celery_testing.py and scheduler_testing.py files.
depends on D937
Differential D948
Replace task tests (in test_task.py) with pytest-based ones douardda on Jan 15 2019, 11:36 AM. Authored by
Details Add a 'scheduler' pytest fixture that created a scheduler usable for tests Also remove now useless celery_testing.py and scheduler_testing.py files. depends on D937
Diff Detail
Event TimelineComment Actions Build has FAILED Link to build: https://jenkins.softwareheritage.org/job/DSCH/job/tox/97/ Comment Actions
They are used in archiver and indexer tests. Comment Actions Build has FAILED Link to build: https://jenkins.softwareheritage.org/job/DSCH/job/tox/98/ Comment Actions backend_tasks = run_ready_tasks(swh_scheduler, swh_app) assert backend_tasks for task in backend_tasks: # Make sure the task completed AsyncResult(id=task['backend_id']).get() Looks like a recurring pattern. Could you write a wrapper of run_ready_tasks to do it? (or add an argument to run_ready_tasks) Comment Actions Yes I have this on my todo list, but I was not sure what was really needed here. Comment Actions Build has FAILED Link to build: https://jenkins.softwareheritage.org/job/DSCH/job/tox/103/ |