forked from qt-creator/qt-creator
SquishTests: Ignore non-kit items
Change-Id: Id9b209171fc296fc65b6c6c1755df491ba7d4997 Reviewed-by: Robert Löhning <robert.loehning@qt.io>
This commit is contained in:
@@ -8,7 +8,9 @@ def verifyProjectsMode(expectedKits):
|
||||
bAndRIndex = getQModelIndexStr("text='Build & Run'",
|
||||
":Projects.ProjectNavigationTreeView")
|
||||
foundKits = dumpItems(treeView.model(), waitForObject(bAndRIndex))
|
||||
relevantKits = list(filter(lambda x: 'Python' not in x,foundKits)) # ignore Python kits
|
||||
# ignore Python kits and non-kit item
|
||||
excludes = ('Python', 'Hide Inactive Kits', 'Show All Kits')
|
||||
relevantKits = list(filter(lambda x: all(ex not in x for ex in excludes), foundKits))
|
||||
test.compare(len(relevantKits), len(expectedKits), "Verify number of listed kits.")
|
||||
test.compare(set(relevantKits), set(expectedKits), "Verify if expected kits are listed.")
|
||||
hasKits = len(expectedKits) > 0
|
||||
|
||||
Reference in New Issue
Block a user