diff options
author | Jason McDonald <jason.mcdonald@nokia.com> | 2012-02-13 14:18:57 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-13 06:28:16 +0100 |
commit | 06ce7555d46dcc7eb943eee968f966ec043c4c4a (patch) | |
tree | a05cf48a3d706385798b08ad93b0d3f0f2b7fb0a | |
parent | 3bcee7b2ffac747b28e28efdaa025ad6ff0fd568 (diff) | |
download | qtlocation-06ce7555d46dcc7eb943eee968f966ec043c4c4a.tar.gz |
Remove duplicate definitions of testlib macros.
QTRY_VERIFY_WITH_TIMEOUT and QTRY_COMPARE_WITH_TIMEOUT are now included
in qtestlib. QTRY_COMPARE_WITH_TIMEOUT_RANGE was unused.
Change-Id: I11441452b1b8129109ea43b8c24e94e4cb10b731
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
-rw-r--r-- | tests/auto/qgeocoordinate/qlocationtestutils_p.h | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/tests/auto/qgeocoordinate/qlocationtestutils_p.h b/tests/auto/qgeocoordinate/qlocationtestutils_p.h index de382fc9..67f7c322 100644 --- a/tests/auto/qgeocoordinate/qlocationtestutils_p.h +++ b/tests/auto/qgeocoordinate/qlocationtestutils_p.h @@ -45,36 +45,6 @@ #include <QString> #include <QTest> -#if !defined(QTRY_COMPARE_WITH_TIMEOUT) // Now provided by QTestLib. #fixme: Remove entirely. - -#define QTRY_COMPARE_WITH_TIMEOUT(a,e,t) \ - for (int _i = 0; _i < t; _i += 100) { \ - if ((a) >= (e)) break; \ - QTest::qWait(100); \ - } \ - QCOMPARE(a, e) - -#define QTRY_VERIFY_WITH_TIMEOUT(a,t) \ - for (int _i = 0; _i < t; _i += 100) { \ - if (a) break; \ - QTest::qWait(100); \ - } \ - QVERIFY(a) - -#define QTRY_COMPARE_WITH_TIMEOUT_RANGE(a,e,t1,t2) { \ - int _i; \ - for (_i = 0; _i < t1; _i += 100) { \ - if ((a) >= (e)) {char str[100]; sprintf(str, "Got signal earlier than expected, i = %d, n = %d", _i, e);QFAIL((const char *)str); break;} \ - QTest::qWait(100); \ - } \ - for (; _i < t2; _i += 100) { \ - if ((a) >= (e)) break; \ - QTest::qWait(100); \ - } } \ - QCOMPARE(a, e) - -#endif // !defined(QTRY_COMPARE_WITH_TIMEOUT) - class QLocationTestUtils { public: |