diff options
author | Kari Oikarinen <kari.oikarinen@qt.io> | 2019-01-08 08:18:48 +0200 |
---|---|---|
committer | Kari Oikarinen <kari.oikarinen@qt.io> | 2019-01-08 08:18:48 +0200 |
commit | 71534dcff9d122891b5059baccd7f3dec21e063a (patch) | |
tree | 64de776f804cef2856fda6c59dfdc7236e26612a /tests | |
parent | 1006eb36e58832b7142d1dfacbd1f878938fc155 (diff) | |
parent | 520657bdfa0aba68e31758c5952a01c45940cd8f (diff) |
Merge 5.12 into 5.12.1
Change-Id: I442b103e352bc49b35fb816104c87c112e2fd958
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/controls/data/tst_textfield.qml | 27 | ||||
-rw-r--r-- | tests/auto/qquickstyle/tst_qquickstyle.cpp | 4 |
2 files changed, 31 insertions, 0 deletions
diff --git a/tests/auto/controls/data/tst_textfield.qml b/tests/auto/controls/data/tst_textfield.qml index ee2d1a54..2ee1db41 100644 --- a/tests/auto/controls/data/tst_textfield.qml +++ b/tests/auto/controls/data/tst_textfield.qml @@ -51,6 +51,7 @@ import QtQuick 2.12 import QtTest 1.0 import QtQuick.Controls 2.12 +import QtQuick.Layouts 1.12 TestCase { id: testCase @@ -633,4 +634,30 @@ TestCase { compare(control.background.height, 100) } + Component { + id: layoutComponent + + ColumnLayout { + anchors.fill: parent + + property alias textField: textField + + TextField { + id: textField + placeholderText: "Placeholder" + Layout.fillWidth: true + } + } + } + + function test_inLayout() { + var layout = createTemporaryObject(layoutComponent, testCase) + verify(layout) + + var control = layout.textField + verify(control) + + compare(control.width, control.parent.width) + compare(control.background.width, control.width) + } } diff --git a/tests/auto/qquickstyle/tst_qquickstyle.cpp b/tests/auto/qquickstyle/tst_qquickstyle.cpp index 8d09a293..f5207a96 100644 --- a/tests/auto/qquickstyle/tst_qquickstyle.cpp +++ b/tests/auto/qquickstyle/tst_qquickstyle.cpp @@ -159,7 +159,11 @@ void tst_QQuickStyle::availableStyles() QQuickStyle::addStylePath(path); QStringList paths = QQuickStylePrivate::stylePaths(); +#ifndef Q_OS_WIN QVERIFY(paths.contains(path)); +#else + QVERIFY(paths.contains(path, Qt::CaseInsensitive)); +#endif const QStringList styles = QQuickStyle::availableStyles(); QVERIFY(!styles.isEmpty()); |