Refactor the swh_scheduler fixture
2 points:
- make it more generic so that stuff like the indexer_scheduler fixture in swh-indexer!89 (closed) is not needed any more
- better handling of the call to run_ready_tasks() as pointed by @vlorentz on https://forge.softwareheritage.org/!44
Migrated from T1473 (view on Phabricator)