summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2013-08-14 09:05:42 +0200
committerFrederik Gladhorn <frederik.gladhorn@digia.com>2013-08-14 09:06:31 +0200
commit5c23199d4e8ff21661dfa5aacc13149178e78cab (patch)
tree322aee61581d7c85f1ccb65e47d1e79eba1ba6c9 /tests/auto/gui
parent252bad7c589e03d3e12df02354b00a84d8e3159a (diff)
parentc8d9b17367cfdcb034d11f8a168ca4ae3993e7c3 (diff)
Merge remote-tracking branch 'origin/stable' into dev
Conflicts: configure mkspecs/macx-xcode/Info.plist.app mkspecs/macx-xcode/Info.plist.lib qmake/doc/qmake.qdocconf src/corelib/global/qglobal.h tests/auto/other/exceptionsafety/exceptionsafety.pro tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp Change-Id: I3c769a4a82dc2e99a12c69123fbf17613fd2ac2a
Diffstat (limited to 'tests/auto/gui')
-rw-r--r--tests/auto/gui/kernel/kernel.pro1
-rw-r--r--tests/auto/gui/kernel/qguieventloop/qguieventloop.pro3
-rw-r--r--tests/auto/gui/kernel/qwindow/tst_qwindow.cpp20
-rw-r--r--tests/auto/gui/text/qfont/tst_qfont.cpp9
-rw-r--r--tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp4
-rw-r--r--tests/auto/gui/text/qrawfont/tst_qrawfont.cpp4
6 files changed, 41 insertions, 0 deletions
diff --git a/tests/auto/gui/kernel/kernel.pro b/tests/auto/gui/kernel/kernel.pro
index 85a81de632..0d0a300eac 100644
--- a/tests/auto/gui/kernel/kernel.pro
+++ b/tests/auto/gui/kernel/kernel.pro
@@ -6,6 +6,7 @@ SUBDIRS=\
qevent \
qfileopenevent \
qguieventdispatcher \
+ qguieventloop \
qguimetatype \
qguitimer \
qguivariant \
diff --git a/tests/auto/gui/kernel/qguieventloop/qguieventloop.pro b/tests/auto/gui/kernel/qguieventloop/qguieventloop.pro
new file mode 100644
index 0000000000..633386fa75
--- /dev/null
+++ b/tests/auto/gui/kernel/qguieventloop/qguieventloop.pro
@@ -0,0 +1,3 @@
+include(../../../corelib/kernel/qeventloop/qeventloop.pro)
+TARGET = tst_qguieventloop
+QT += gui
diff --git a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
index b4208949b0..7ad7880330 100644
--- a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
+++ b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
@@ -59,6 +59,7 @@ class tst_QWindow: public QObject
private slots:
void eventOrderOnShow();
+ void resizeEventAfterResize();
void mapGlobal();
void positioning();
void isExposed();
@@ -168,6 +169,25 @@ void tst_QWindow::eventOrderOnShow()
QVERIFY(window.eventIndex(QEvent::Resize) < window.eventIndex(QEvent::Expose));
}
+void tst_QWindow::resizeEventAfterResize()
+{
+ // Some platforms enforce minimum widths for windows, which can cause extra resize
+ // events, so set the width to suitably large value to avoid those.
+ QRect geometry(QGuiApplication::primaryScreen()->availableGeometry().topLeft() + QPoint(20, 20), QSize(300, 40));
+
+ Window window;
+ window.setGeometry(geometry);
+ window.show();
+
+ QTRY_COMPARE(window.received(QEvent::Resize), 1);
+
+ // QTBUG-32706
+ // Make sure we get a resizeEvent after calling resize
+ window.resize(400, 100);
+
+ QTRY_COMPARE(window.received(QEvent::Resize), 2);
+}
+
void tst_QWindow::positioning()
{
if (!QGuiApplicationPrivate::platformIntegration()->hasCapability(
diff --git a/tests/auto/gui/text/qfont/tst_qfont.cpp b/tests/auto/gui/text/qfont/tst_qfont.cpp
index b8cce2671f..acb55c2d86 100644
--- a/tests/auto/gui/text/qfont/tst_qfont.cpp
+++ b/tests/auto/gui/text/qfont/tst_qfont.cpp
@@ -685,6 +685,15 @@ void tst_QFont::defaultFamily()
break;
}
}
+
+#if defined(Q_OS_MAC)
+ if (QSysInfo::MacintoshVersion == QSysInfo::MV_10_8) {
+ QEXPECT_FAIL("serif", "See QTBUG-32834", Continue);
+ QEXPECT_FAIL("monospace", "See QTBUG-32834", Continue);
+ QEXPECT_FAIL("cursive", "See QTBUG-32834", Continue);
+ QEXPECT_FAIL("fantasy", "See QTBUG-32834", Continue);
+ }
+#endif
QVERIFY2(isAcceptable, msgNotAcceptableFont(familyForHint, acceptableFamilies));
}
diff --git a/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp b/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
index 6b06424ad7..3f6eaae89b 100644
--- a/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
+++ b/tests/auto/gui/text/qglyphrun/tst_qglyphrun.cpp
@@ -502,6 +502,10 @@ void tst_QGlyphRun::drawMultiScriptText2()
drawGlyphs.save("drawMultiScriptText2_drawGlyphIndexes.png");
#endif
+#ifdef Q_OS_MACX
+ if (drawGlyphs.toImage() != textLayoutDraw.toImage())
+ QEXPECT_FAIL("", "See QTBUG-32690", Continue);
+#endif // Q_OS_MACX
QCOMPARE(drawGlyphs, textLayoutDraw);
}
diff --git a/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp b/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp
index ae6e450301..19f60baa29 100644
--- a/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp
+++ b/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp
@@ -675,6 +675,10 @@ void tst_QRawFont::fromFont()
QFontDatabase fontDatabase;
int id = fontDatabase.addApplicationFont(fileName);
+#ifdef Q_OS_MACX
+ if (QSysInfo::MacintoshVersion == QSysInfo::MV_10_8)
+ QEXPECT_FAIL("", "See QTBUG-32654", Abort);
+#endif
QVERIFY(id >= 0);
QFont font(familyName);