mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-02-23 11:21:13 +00:00
add a message when list of valid/invalid excuses fails to validate
This commit is contained in:
parent
f0e46d7bfa
commit
dfe2205bc7
@ -619,10 +619,15 @@ class ExcuseFinder(object):
|
||||
|
||||
# check that the list of actionable items matches the list of valid
|
||||
# excuses
|
||||
assert valid == {x for x in excuses if excuses[x].is_valid}
|
||||
assert_sets_equal(valid, {x for x in excuses if excuses[x].is_valid})
|
||||
|
||||
# check that the rdeps for all invalid excuses were invalidated
|
||||
assert invalidated == {x for x in excuses if not excuses[x].is_valid}
|
||||
assert_sets_equal(invalidated, {x for x in excuses if not excuses[x].is_valid})
|
||||
|
||||
actionable_items = {x for x in actionable_items if x.name in valid}
|
||||
return excuses, actionable_items
|
||||
|
||||
|
||||
def assert_sets_equal(a, b):
|
||||
if a != b:
|
||||
raise AssertionError("sets not equal a-b {} b-a {}".format(a-b, b-a))
|
||||
|
Loading…
x
Reference in New Issue
Block a user