core: Align listers' task output (hg/git tasks) with expected format

Related to T2134
Related to D2409
Related to D2410
This commit is contained in:
Antoine R. Dumont (@ardumont) 2019-12-06 17:35:24 +01:00
parent 5d096d511c
commit 5ab9d67d67
No known key found for this signature in database
GPG key ID: 52E2E9840D10C3B8
9 changed files with 46 additions and 38 deletions

View file

@ -55,14 +55,12 @@ def test_lister_gitlab(swh_listers, requests_mock_datadir):
assert row['type'] == 'load-git'
# arguments check
args = row['arguments']['args']
assert len(args) == 1
url = args[0]
assert url.startswith('https://gitlab.com')
assert len(args) == 0
# kwargs
kwargs = row['arguments']['kwargs']
assert kwargs == {}
url = kwargs['url']
assert url.startswith('https://gitlab.com')
assert row['policy'] == 'recurring'
assert row['priority'] is None