Commit 6fe810f5 authored by Robert Loehning's avatar Robert Loehning
Browse files

Squish: Compare sets directly instead of differences

Generates better output with less code.

Change-Id: I3a5fa02c5aca97561e20dc4ddf4153596a3a60ae
Reviewed-by: default avatarChristian Stenger <>
parent 34131303
......@@ -106,9 +106,8 @@ def testSaveChangesAndMakeWritable(modifiedFiles, readOnlyFiles):
items = map(os.path.expanduser, map(os.path.join, dumpItems(filesTree.model(), column=4),
dumpItems(filesTree.model(), column=3)))
difference = set(readOnlyFiles) ^ set(items)
test.verify(len(difference) == 0, "Verifying whether all modified files without write "
"permission are listed."), set(items),
"Verifying whether all modified files without write permission are listed.")
clickButton("{text='Change Permission' type='QPushButton' visible='1' unnamed='1' "
......@@ -299,12 +299,8 @@ def __compareDebuggers__(foundDebuggers, expectedDebuggers):
foundSet = set(foundDebuggers)
expectedSet = set(expectedDebuggers)
if not (test.verify(not foundSet.symmetric_difference(expectedSet),
"Verifying expected and found debuggers match.")):
test.log("Found debuggers: %s" % foundDebuggers,
"Expected debuggers: %s" % expectedDebuggers)
return False
return True
return, expectedSet,
"Verifying expected and found debuggers match.")
def __lowerStrs__(iterable):
for it in iterable:
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment