diff options
author | Jason McDonald <jason.mcdonald@nokia.com> | 2011-10-06 18:56:31 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-10-07 04:30:30 +0200 |
commit | 924d810dbdcd5b5b0fa860922b2487ea9062d002 (patch) | |
tree | b14117ac5b9a2d8d02a502adbd00b94ba5eef424 /tests/auto/gui/text/qfont | |
parent | 13251dcaea443d2f228fc797e54318191048e588 (diff) |
Avoid using QSKIP in lieu of compile-time checks
QSKIP is intended to be used to skip test functions that are found at
run-time to be inapplicable or unsafe. If a test function can be
determined to be inapplicable at compile-time, the entire test function
should be omitted instead of replacing the body of the test function
with a QSKIP, which only serves to slow down test runs and to inflate
test run-rates with empty, inapplicable tests.
Task-number: QTQAINFRA-278
Change-Id: I95feba3edbfa092c0ef4d85bb8c6877bd6be698e
Reviewed-on: http://codereview.qt-project.org/6128
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Diffstat (limited to 'tests/auto/gui/text/qfont')
-rw-r--r-- | tests/auto/gui/text/qfont/tst_qfont.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/gui/text/qfont/tst_qfont.cpp b/tests/auto/gui/text/qfont/tst_qfont.cpp index 88c9486309..d21c673b6d 100644 --- a/tests/auto/gui/text/qfont/tst_qfont.cpp +++ b/tests/auto/gui/text/qfont/tst_qfont.cpp @@ -67,7 +67,9 @@ public slots: void cleanup(); private slots: void getSetCheck(); +#ifndef Q_WS_WIN void exactMatch(); +#endif void compare(); void resolve(); void resetFont(); @@ -148,6 +150,8 @@ void tst_QFont::cleanup() // This will be executed immediately after each test is run. } +// Exact matching on windows misses a lot because of the sample chars. +#ifndef Q_WS_WIN void tst_QFont::exactMatch() { QFont font; @@ -156,11 +160,6 @@ void tst_QFont::exactMatch() font = QFont( "BogusFont", 33 ); QVERIFY( !font.exactMatch() ); -#ifdef Q_WS_WIN - QSKIP("Exact matching on windows misses a lot because of the sample chars", SkipAll); - return; -#endif - #ifdef Q_WS_X11 QVERIFY(QFont("sans").exactMatch()); QVERIFY(QFont("sans-serif").exactMatch()); @@ -309,6 +308,7 @@ void tst_QFont::exactMatch() } } } +#endif void tst_QFont::italicOblique() { |