Squish: Build Qml debug lib only if necessary

Change-Id: I90cf1f9e57d39211ea151b1cfc52e27f4ecaf654
Reviewed-by: Robert Loehning <robert.loehning@digia.com>
This commit is contained in:
Christian Stenger
2013-08-22 16:25:33 +02:00
parent 42bf1dba3a
commit 4c0778786b

View File

@@ -204,25 +204,33 @@ def verifyBuildConfig(targetCount, currentTarget, shouldBeDebug=False, enableSha
test.compare(buildCfCombo.currentText, 'Debug', "Verifying whether it's a debug build") test.compare(buildCfCombo.currentText, 'Debug', "Verifying whether it's a debug build")
else: else:
test.compare(buildCfCombo.currentText, 'Release', "Verifying whether it's a release build") test.compare(buildCfCombo.currentText, 'Release', "Verifying whether it's a release build")
try: if enableQmlDebug:
libLabel = waitForObject(":scrollArea.Library not available_QLabel", 2000) try:
mouseClick(libLabel, libLabel.width - 10, libLabel.height / 2, 0, Qt.LeftButton) libLabel = waitForObject(":scrollArea.Library not available_QLabel", 2000)
except: mouseClick(libLabel, libLabel.width - 10, libLabel.height / 2, 0, Qt.LeftButton)
pass except:
# Since waitForObject waits for the object to be enabled, pass
# it will wait here until compilation of the debug libraries has finished. # Since waitForObject waits for the object to be enabled,
qmlDebugCheckbox = waitForObject(":scrollArea.qmlDebuggingLibraryCheckBox_QCheckBox", 150000) # it will wait here until compilation of the debug libraries has finished.
if qmlDebugCheckbox.checked != enableQmlDebug: qmlDebugCheckbox = waitForObject(":scrollArea.qmlDebuggingLibraryCheckBox_QCheckBox", 150000)
clickButton(qmlDebugCheckbox) if qmlDebugCheckbox.checked != enableQmlDebug:
# Don't rebuild now clickButton(qmlDebugCheckbox)
clickButton(waitForObject(":QML Debugging.No_QPushButton", 5000)) # Don't rebuild now
try: clickButton(waitForObject(":QML Debugging.No_QPushButton", 5000))
problemFound = waitForObject("{window=':Qt Creator_Core::Internal::MainWindow' " try:
"type='QLabel' name='problemLabel' visible='1'}", 1000) problemFound = waitForObject("{window=':Qt Creator_Core::Internal::MainWindow' "
if problemFound: "type='QLabel' name='problemLabel' visible='1'}", 1000)
test.warning('%s' % problemFound.text) if problemFound:
except: test.warning('%s' % problemFound.text)
pass except:
pass
else:
qmlDebugCheckbox = findObject(":scrollArea.qmlDebuggingLibraryCheckBox_QCheckBox")
if qmlDebugCheckbox.enabled and qmlDebugCheckbox.checked:
test.log("Qml debugging libraries are available - unchecking qml debugging.")
clickButton(qmlDebugCheckbox)
# Don't rebuild now
clickButton(waitForObject(":QML Debugging.No_QPushButton", 5000))
clickButton(waitForObject(":scrollArea.Details_Utils::DetailsButton")) clickButton(waitForObject(":scrollArea.Details_Utils::DetailsButton"))
switchViewTo(ViewConstants.EDIT) switchViewTo(ViewConstants.EDIT)