test: fix tst_QPushButton::sizeHint() with Mac style on Mac OS X

The style name should be macintosh, not mac.

This also reverts commit 2f46ea9fd6.

Task-number: QTBUG-23680
Change-Id: I7fd06da165ca5bc99801c13af13fdb3d35119566
Reviewed-by: Sergio Ahumada <sahumada@blackberry.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This commit is contained in:
Liang Qi 2014-01-07 08:33:33 +01:00 committed by The Qt Project
parent 3b2143bdf7
commit dbaff44ff1

View File

@ -566,7 +566,7 @@ void tst_QPushButton::sizeHint_data()
QTest::newRow("gtk") << QString::fromLatin1("gtk");
#endif
#if defined(Q_OS_MAC) && !defined(QT_NO_STYLE_MAC)
QTest::newRow("mac") << QString::fromLatin1("mac");
QTest::newRow("macintosh") << QString::fromLatin1("macintosh");
#endif
#if !defined(QT_NO_STYLE_FUSION)
QTest::newRow("fusion") << QString::fromLatin1("fusion");
@ -589,11 +589,6 @@ void tst_QPushButton::sizeHint()
{
QFETCH(QString, stylename);
#ifdef Q_OS_MAC
if (stylename == "mac")
QSKIP("QStyleFactory cannot create the Mac style, see QTBUG-23680");
#endif
QStyle *style = QStyleFactory::create(stylename);
if (!style)
QFAIL(qPrintable(QString::fromLatin1("Cannot create style: %1").arg(stylename)));