mirror of
https://github.com/theupdateframework/python-tuf
synced 2026-05-24 10:08:28 +00:00
Specify correct number of arguments for modified _visit_child_role()
This commit is contained in:
parent
44ebd65b34
commit
09f6261b4a
1 changed files with 3 additions and 3 deletions
|
|
@ -1327,18 +1327,18 @@ def test_10__visit_child_role(self):
|
|||
|
||||
child_role = targets_role['delegations']['roles'][0]
|
||||
self.assertEqual(self.repository_updater._visit_child_role(child_role,
|
||||
'/file3.txt'), child_role['name'])
|
||||
'/file3.txt', targets_role['delegations']), child_role['name'])
|
||||
|
||||
# Test path hash prefixes.
|
||||
child_role['path_hash_prefixes'] = ['8baf', '0000']
|
||||
self.assertEqual(self.repository_updater._visit_child_role(child_role,
|
||||
'/file3.txt'), child_role['name'])
|
||||
'/file3.txt', targets_role['delegations']), child_role['name'])
|
||||
|
||||
# Test if both 'path' and 'path_hash_prefixes' is missing.
|
||||
del child_role['paths']
|
||||
del child_role['path_hash_prefixes']
|
||||
self.assertRaises(tuf.FormatError, self.repository_updater._visit_child_role,
|
||||
child_role, child_role['name'])
|
||||
child_role, targets_role['delegations'], child_role['name'])
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue