forked from qt-creator/qt-creator
SquishTests: Replace wait condition strings with lambdas
Squish allows passing wait conditions as strings containing python code. The only advantage I see is that the notation is a little shorter than using a lambda. On the other hand, the strings can't get proper syntax highlighting and cause false positive warnings about unused variables. Change-Id: I226840fa26dc75d07d89f20647d069e2e866bbc9 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -21,13 +21,13 @@ def main():
|
||||
openQmakeProject(os.path.join(pathSpeedcrunch, "src", "speedcrunch.pro"),
|
||||
[Targets.DESKTOP_5_14_1_DEFAULT])
|
||||
# Wait for parsing to complete
|
||||
waitFor("runButton.enabled", 30000)
|
||||
waitFor(lambda: runButton.enabled, 30000)
|
||||
# Starting before opening, because this is where Creator froze (QTCREATORBUG-10733)
|
||||
startopening = datetime.utcnow()
|
||||
openQmakeProject(pathCreator, [Targets.DESKTOP_5_14_1_DEFAULT])
|
||||
# Wait for parsing to complete
|
||||
startreading = datetime.utcnow()
|
||||
waitFor("runButton.enabled", 300000)
|
||||
waitFor(lambda: runButton.enabled, 300000)
|
||||
secondsOpening = (datetime.utcnow() - startopening).seconds
|
||||
secondsReading = (datetime.utcnow() - startreading).seconds
|
||||
timeoutOpen = 45
|
||||
|
Reference in New Issue
Block a user