aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/shared
diff options
context:
space:
mode:
authorMitch Curtis <mitch.curtis@qt.io>2021-04-27 14:43:31 +0200
committerMitch Curtis <mitch.curtis@qt.io>2021-04-27 17:40:07 +0200
commitb86842b22706e23d7319aa373d8c6c4b19a3688f (patch)
tree9f2ee18ec9976e1f0b7321bcf9c997e910d72525 /tests/auto/shared
parentcc2d45fd72a764312be9757ef96cc9abd5d1b423 (diff)
QQuickApplicationHelper: error-check after createWithInitialProperties
Unlike create(), it does produce errors that will not always be noticeable if we don't check for them. Change-Id: Ia3adad6937de5f9b923e0e1593486b8ae11c3c68 Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'tests/auto/shared')
-rw-r--r--tests/auto/shared/visualtestutil.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/shared/visualtestutil.h b/tests/auto/shared/visualtestutil.h
index 122dd415..215a487b 100644
--- a/tests/auto/shared/visualtestutil.h
+++ b/tests/auto/shared/visualtestutil.h
@@ -142,7 +142,7 @@ namespace QQuickVisualTestUtil
component.loadUrl(testCase->testFileUrl(testFilePath));
QObject *rootObject = component.createWithInitialProperties(initialProperties);
cleanup.reset(rootObject);
- if (!rootObject) {
+ if (component.isError() || !rootObject) {
errorMessage = QString::fromUtf8("Failed to create window: %1").arg(component.errorString()).toUtf8();
return;
}