diff options
Diffstat (limited to 'tests/auto/widgets')
9 files changed, 37 insertions, 19 deletions
diff --git a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp index 9d4b640272..6924b78397 100644 --- a/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp +++ b/tests/auto/widgets/graphicsview/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp @@ -150,7 +150,8 @@ public: m_fnConstraint = fnConstraint; } - QSizeF m_sizeHints[Qt::NSizeHints]; + // Initializer {} is a workaround for gcc bug 68949 + QSizeF m_sizeHints[Qt::NSizeHints] {}; QSizeF (*m_fnConstraint)(Qt::SizeHint, const QSizeF &); }; @@ -280,8 +281,10 @@ struct ItemDesc int m_rowSpan; int m_colSpan; QSizePolicy m_sizePolicy; - QSizeF m_sizeHints[Qt::NSizeHints]; - QSizeF m_sizes[Qt::NSizeHints]; + + // Initializer {} is a workaround for gcc bug 68949 + QSizeF m_sizeHints[Qt::NSizeHints] {}; + QSizeF m_sizes[Qt::NSizeHints] {}; Qt::Alignment m_align; Qt::Orientation m_constraintOrientation; diff --git a/tests/auto/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp index 322af7c236..0f5277710c 100644 --- a/tests/auto/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp +++ b/tests/auto/widgets/graphicsview/qgraphicslinearlayout/tst_qgraphicslinearlayout.cpp @@ -165,7 +165,8 @@ public: return QGraphicsWidget::sizeHint(which, constraint); } - QSizeF m_sizeHints[Qt::NSizeHints]; + // Initializer {} is a workaround for gcc bug 68949 + QSizeF m_sizeHints[Qt::NSizeHints] {}; QBrush m_brush; }; diff --git a/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp b/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp index 5ab24d6878..76b25cdb52 100644 --- a/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp +++ b/tests/auto/widgets/graphicsview/qgraphicsview/tst_qgraphicsview.cpp @@ -56,6 +56,8 @@ #include <private/qgraphicsview_p.h> #include "../../../shared/platforminputcontext.h" #include <private/qinputmethod_p.h> +#include <private/qguiapplication_p.h> +#include <qpa/qplatformintegration.h> #include "tst_qgraphicsview.h" @@ -664,6 +666,9 @@ void tst_QGraphicsView::viewport() #ifndef QT_NO_OPENGL void tst_QGraphicsView::openGLViewport() { + if (!QGuiApplicationPrivate::platformIntegration()->hasCapability(QPlatformIntegration::OpenGL)) + QSKIP("QOpenGL is not supported on this platform."); + QGraphicsScene scene; scene.setBackgroundBrush(Qt::white); scene.addText("GraphicsView"); diff --git a/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro b/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro index ea4e9d4620..61939983e6 100644 --- a/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro +++ b/tests/auto/widgets/itemviews/qdirmodel/qdirmodel.pro @@ -3,6 +3,9 @@ TARGET = tst_qdirmodel QT += widgets testlib SOURCES += tst_qdirmodel.cpp +INCLUDEPATH += ../../../../shared/ +HEADERS += ../../../../shared/emulationdetector.h + wince* { addit.files = dirtest\\test1\\* addit.path = dirtest\\test1 diff --git a/tests/auto/widgets/itemviews/qdirmodel/tst_qdirmodel.cpp b/tests/auto/widgets/itemviews/qdirmodel/tst_qdirmodel.cpp index 30109952c7..2044704e76 100644 --- a/tests/auto/widgets/itemviews/qdirmodel/tst_qdirmodel.cpp +++ b/tests/auto/widgets/itemviews/qdirmodel/tst_qdirmodel.cpp @@ -32,6 +32,7 @@ #include <qtreeview.h> #include <qdir.h> #include <qdebug.h> +#include "emulationdetector.h" class tst_QDirModel : public QObject { @@ -615,6 +616,9 @@ void tst_QDirModel::task196768_sorting() #if defined(Q_OS_ANDROID) QEXPECT_FAIL("", "QTBUG-43818", Continue); +#else + if (EmulationDetector::isRunningArmOnX86()) + QEXPECT_FAIL("", "QTBUG-43818", Continue); #endif QCOMPARE(index.data(), index2.data()); diff --git a/tests/auto/widgets/kernel/qwidget/BLACKLIST b/tests/auto/widgets/kernel/qwidget/BLACKLIST index 4a49a94c5d..9981fd3447 100644 --- a/tests/auto/widgets/kernel/qwidget/BLACKLIST +++ b/tests/auto/widgets/kernel/qwidget/BLACKLIST @@ -1,6 +1,7 @@ # OSX QTBUG-25300 QTBUG-45502 [normalGeometry] ubuntu-14.04 +ubuntu-16.04 [saveRestoreGeometry] ubuntu-14.04 ubuntu-16.04 diff --git a/tests/auto/widgets/widgets/qmenubar/BLACKLIST b/tests/auto/widgets/widgets/qmenubar/BLACKLIST index 4f9508266c..06776d961d 100644 --- a/tests/auto/widgets/widgets/qmenubar/BLACKLIST +++ b/tests/auto/widgets/widgets/qmenubar/BLACKLIST @@ -1,7 +1,9 @@ [check_menuPosition] ubuntu-14.04 +ubuntu-16.04 [taskQTBUG4965_escapeEaten] ubuntu-14.04 +ubuntu-16.04 redhatenterpriselinuxworkstation-6.6 [task256322_highlight] osx diff --git a/tests/auto/widgets/widgets/qmenubar/tst_qmenubar_mac.mm b/tests/auto/widgets/widgets/qmenubar/tst_qmenubar_mac.mm index af93c18712..823ca7edfa 100644 --- a/tests/auto/widgets/widgets/qmenubar/tst_qmenubar_mac.mm +++ b/tests/auto/widgets/widgets/qmenubar/tst_qmenubar_mac.mm @@ -5,7 +5,7 @@ ** ** This file is part of the test suite of the Qt Toolkit. ** -** $QT_BEGIN_LICENSE:LGPL$ +** $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 @@ -14,24 +14,13 @@ ** 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 3 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL3 included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 3 requirements -** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. -** ** GNU General Public License Usage ** Alternatively, this file may be used under the terms of the GNU -** General Public License version 2.0 or (at your option) the GNU General -** Public license version 3 or any later version approved by the KDE Free -** Qt Foundation. The licenses are as published by the Free Software -** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 +** 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-2.0.html and -** https://www.gnu.org/licenses/gpl-3.0.html. +** be met: https://www.gnu.org/licenses/gpl-3.0.html. ** ** $QT_END_LICENSE$ ** diff --git a/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp b/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp index 778ff1d932..c7fca550e5 100644 --- a/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp +++ b/tests/auto/widgets/widgets/qopenglwidget/tst_qopenglwidget.cpp @@ -39,12 +39,15 @@ #include <QtWidgets/QStackedWidget> #include <QtTest/QtTest> #include <QSignalSpy> +#include <private/qguiapplication_p.h> +#include <qpa/qplatformintegration.h> class tst_QOpenGLWidget : public QObject { Q_OBJECT private slots: + void initTestCase(); void create(); void clearAndGrab(); void clearAndResizeAndGrab(); @@ -60,6 +63,13 @@ private slots: void stackWidgetOpaqueChildIsVisible(); }; +void tst_QOpenGLWidget::initTestCase() +{ + // See QOpenGLWidget constructor + if (!QGuiApplicationPrivate::platformIntegration()->hasCapability(QPlatformIntegration::RasterGLSurface)) + QSKIP("QOpenGLWidget is not supported on this platform."); +} + void tst_QOpenGLWidget::create() { QScopedPointer<QOpenGLWidget> w(new QOpenGLWidget); |