diff options
Diffstat (limited to 'tests/auto/widgets/kernel/qgridlayout')
-rw-r--r-- | tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro | 1 | ||||
-rw-r--r-- | tests/auto/widgets/kernel/qgridlayout/tst_qgridlayout.cpp | 39 |
2 files changed, 18 insertions, 22 deletions
diff --git a/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro b/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro index febcee6c55..ee64f8538f 100644 --- a/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro +++ b/tests/auto/widgets/kernel/qgridlayout/qgridlayout.pro @@ -1,5 +1,4 @@ CONFIG += testcase -CONFIG += parallel_test TARGET = tst_qgridlayout QT += widgets widgets-private testlib diff --git a/tests/auto/widgets/kernel/qgridlayout/tst_qgridlayout.cpp b/tests/auto/widgets/kernel/qgridlayout/tst_qgridlayout.cpp index 1e67c675ef..07dcfca28f 100644 --- a/tests/auto/widgets/kernel/qgridlayout/tst_qgridlayout.cpp +++ b/tests/auto/widgets/kernel/qgridlayout/tst_qgridlayout.cpp @@ -1,31 +1,26 @@ /**************************************************************************** ** -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ ** ** This file is part of the test suite of the Qt Toolkit. ** -** $QT_BEGIN_LICENSE:LGPL21$ +** $QT_BEGIN_LICENSE:GPL-EXCEPT$ ** Commercial License Usage ** Licensees holding valid commercial Qt licenses may use this file in ** accordance with the commercial license agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and The Qt Company. For licensing terms -** and conditions see http://www.qt.io/terms-conditions. For further -** information use the contact form at http://www.qt.io/contact-us. +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. ** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 or version 3 as published by the Free -** Software Foundation and appearing in the file LICENSE.LGPLv21 and -** LICENSE.LGPLv3 included in the packaging of this file. Please review the -** following information to ensure the GNU Lesser General Public License -** requirements will be met: https://www.gnu.org/licenses/lgpl.html and -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** As a special exception, The Qt Company gives you certain additional -** rights. These rights are described in The Qt Company LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. ** ** $QT_END_LICENSE$ ** @@ -538,7 +533,8 @@ public: } private: void init(int numPixels = -1){ - setText(QString::fromLatin1("(%1,%2)").arg(sh.width()).arg(sh.height())); + setText(QLatin1Char('(') + QString::number(sh.width()) + + QLatin1Char(',') + QString::number(sh.height()) + QLatin1Char(')')); setFrameStyle(QFrame::Box | QFrame::Plain); setNumberOfPixels(numPixels); } @@ -1432,8 +1428,9 @@ void tst_QGridLayout::layoutSpacing_data() w->setLayout(layout); int pw = up->sizeHint().width(); int ph = up->sizeHint().height(); - QByteArray testName = QString::fromLatin1("arrowpad with %1 empty rows, %2 empty columns").arg(yoff).arg(xoff).toLatin1(); - QTest::newRow(testName.data()) + QByteArray testName = "arrowpad with " + QByteArray::number(yoff) + + " empty rows, " + QByteArray::number(xoff) + " empty columns"; + QTest::newRow(testName.constData()) << w << (PointList() << QPoint(0 + pw + 5, 3) << QPoint(0, 3 + ph + 10) @@ -1686,7 +1683,7 @@ void tst_QGridLayout::replaceWidget() for (int n = 0; n < itemCount; ++n) { int x = n % 3; int y = n / 3; - labels[n] = new QLabel(QString("label %1").arg(n)); + labels[n] = new QLabel(QLatin1String("label ") + QString::number(n)); Qt::Alignment align = (n % 3 ? Qt::AlignLeft : Qt::AlignRight); l->addWidget(labels[n], x * 3, y * 3, (n % 2) + 1, (n + 1) % 2 + 1, align); } |