summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2018-04-10 01:00:25 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2018-04-10 01:00:26 +0200
commite027c7241f073f5fc8c1db88700cc83635b6454f (patch)
tree69920e408b5eeb1547c0241696cfa845af85e4be /tests/auto
parentb2035d38e8dfdfe2ba8da96df5c1174f01dfbb5b (diff)
parent3b85d53913741660473dbc242a48c2ee65d51421 (diff)
Merge remote-tracking branch 'origin/5.11' into dev
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp19
-rw-r--r--tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp8
-rw-r--r--tests/auto/network/ssl/qsslkey/BLACKLIST3
-rw-r--r--tests/auto/other/toolsupport/tst_toolsupport.cpp25
-rw-r--r--tests/auto/printsupport/kernel/qprinter/tst_qprinter.cpp6
5 files changed, 30 insertions, 31 deletions
diff --git a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
index 87fd5c0dc6..993ebbaac6 100644
--- a/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
+++ b/tests/auto/gui/kernel/qclipboard/tst_qclipboard.cpp
@@ -41,10 +41,8 @@ class tst_QClipboard : public QObject
{
Q_OBJECT
private slots:
-#ifdef QT_NO_CLIPBOARD
void initTestCase();
- void cleanupTestCase();
-#else
+#if QT_CONFIG(clipboard)
void init();
#if defined(Q_OS_WIN) || defined(Q_OS_MAC) || defined(Q_OS_QNX)
void copy_exit_paste();
@@ -58,19 +56,16 @@ private slots:
#endif
};
-#ifdef QT_NO_CLIPBOARD
void tst_QClipboard::initTestCase()
{
+#if !QT_CONFIG(clipboard)
QSKIP("This test requires clipboard support");
+#endif
+ if (QGuiApplication::platformName().startsWith(QLatin1String("wayland"), Qt::CaseInsensitive))
+ QSKIP("Wayland: Manipulating the clipboard requires real input events. Can't auto test.");
}
-void tst_QClipboard::cleanupTestCase()
-{
- QSKIP("This test requires clipboard support");
-}
-
-#else
-
+#if QT_CONFIG(clipboard)
void tst_QClipboard::init()
{
#if QT_CONFIG(process)
@@ -436,7 +431,7 @@ void tst_QClipboard::clearBeforeSetText()
QCOMPARE(QGuiApplication::clipboard()->text(), text);
}
-#endif
+#endif // QT_CONFIG(clipboard)
QTEST_MAIN(tst_QClipboard)
diff --git a/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp b/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
index d16d95500b..db5e83e2c7 100644
--- a/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
+++ b/tests/auto/gui/kernel/qtouchevent/tst_qtouchevent.cpp
@@ -608,7 +608,7 @@ void tst_QTouchEvent::basicRawEventTranslation()
touchWidget.setAttribute(Qt::WA_AcceptTouchEvents);
touchWidget.setGeometry(100, 100, 400, 300);
touchWidget.show();
- QVERIFY(QTest::qWaitForWindowActive(&touchWidget));
+ QVERIFY(QTest::qWaitForWindowExposed(&touchWidget));
QPointF pos = touchWidget.rect().center();
QPointF screenPos = touchWidget.mapToGlobal(pos.toPoint());
@@ -741,7 +741,7 @@ void tst_QTouchEvent::multiPointRawEventTranslationOnTouchScreen()
rightWidget.setGeometry(300, 100, 100, 100);
touchWidget.show();
- QVERIFY(QTest::qWaitForWindowActive(&touchWidget));
+ QVERIFY(QTest::qWaitForWindowExposed(&touchWidget));
QPointF leftPos = leftWidget.rect().center();
QPointF rightPos = rightWidget.rect().center();
@@ -968,7 +968,7 @@ void tst_QTouchEvent::multiPointRawEventTranslationOnTouchPad()
rightWidget.setGeometry(300, 100, 100, 100);
touchWidget.show();
- QVERIFY(QTest::qWaitForWindowActive(&touchWidget));
+ QVERIFY(QTest::qWaitForWindowExposed(&touchWidget));
QPointF leftPos = leftWidget.rect().center();
QPointF rightPos = rightWidget.rect().center();
@@ -1184,7 +1184,7 @@ void tst_QTouchEvent::basicRawEventTranslationOfIds()
touchWidget.setAttribute(Qt::WA_AcceptTouchEvents);
touchWidget.setGeometry(100, 100, 400, 300);
touchWidget.show();
- QVERIFY(QTest::qWaitForWindowActive(&touchWidget));
+ QVERIFY(QTest::qWaitForWindowExposed(&touchWidget));
QVarLengthArray<QPointF, 2> pos;
QVarLengthArray<QPointF, 2> screenPos;
diff --git a/tests/auto/network/ssl/qsslkey/BLACKLIST b/tests/auto/network/ssl/qsslkey/BLACKLIST
index a08e1f35eb..c0dfe5eb86 100644
--- a/tests/auto/network/ssl/qsslkey/BLACKLIST
+++ b/tests/auto/network/ssl/qsslkey/BLACKLIST
@@ -1 +1,2 @@
-linux
+redhatenterpriselinuxworkstation-6.6
+rhel-7.4
diff --git a/tests/auto/other/toolsupport/tst_toolsupport.cpp b/tests/auto/other/toolsupport/tst_toolsupport.cpp
index a78bdc34f1..f31a755f9e 100644
--- a/tests/auto/other/toolsupport/tst_toolsupport.cpp
+++ b/tests/auto/other/toolsupport/tst_toolsupport.cpp
@@ -3,27 +3,26 @@
** Copyright (C) 2015 The Qt Company Ltd.
** Contact: http://www.qt.io/licensing/
**
-** This file is part of Qt Creator.
+** This file is part of the test suite of the Qt Toolkit.
**
+** $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 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPL included in the
-** packaging of this file. Please review the following information to
-** ensure the GNU Lesser General Public License version 2.1 requirements
-** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+** 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.
**
-** 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.
+** $QT_END_LICENSE$
**
****************************************************************************/
diff --git a/tests/auto/printsupport/kernel/qprinter/tst_qprinter.cpp b/tests/auto/printsupport/kernel/qprinter/tst_qprinter.cpp
index 314cce0270..a612f0749b 100644
--- a/tests/auto/printsupport/kernel/qprinter/tst_qprinter.cpp
+++ b/tests/auto/printsupport/kernel/qprinter/tst_qprinter.cpp
@@ -592,10 +592,14 @@ void tst_QPrinter::printDialogCompleter()
{
QPrintDialog dialog;
dialog.printer()->setOutputFileName(testPdfFileName(QLatin1String("file")));
+#if defined(Q_OS_WIN) || defined(Q_OS_DARWIN)
+ if (dialog.printer()->outputFormat() != QPrinter::NativeFormat)
+ QSKIP("Dialog cannot be used with non-native formats");
+#endif
dialog.setEnabledOptions(QAbstractPrintDialog::PrintToFile);
dialog.show();
- QTest::qWait(100);
+ QVERIFY(QTest::qWaitForWindowActive(&dialog));
QTest::keyClick(&dialog, Qt::Key_Tab);
QTest::keyClick(&dialog, 'P');