summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjuhvu <qt-info@nokia.com>2011-04-08 15:33:53 +1000
committerjuhvu <qt-info@nokia.com>2011-04-08 15:34:48 +1000
commit03d7a3af0f0300d2e13a82207cbb45e3f5cebc61 (patch)
tree5ec22fb077646677dc6bef2cef81af76f2c6c6d7
parent691970d9e4a73c001246c3be0614a45865d41b22 (diff)
MOBILITY-1955 Test robustness on harmattan and example fixes.
-rw-r--r--examples/declarative-location/flickr/qmllocationflickr.cpp6
-rw-r--r--examples/declarative-location/landmarkmap/qmllandmarkmap.cpp6
-rw-r--r--examples/declarative-location/mapviewer/qmlmapviewer.cpp6
-rw-r--r--src/s60installs/deviceconfiguration/mobilityconfig.prf5
-rw-r--r--tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp58
-rw-r--r--tests/auto/qgeosatelliteinfosource/testqgeosatelliteinfosource.cpp44
6 files changed, 106 insertions, 19 deletions
diff --git a/examples/declarative-location/flickr/qmllocationflickr.cpp b/examples/declarative-location/flickr/qmllocationflickr.cpp
index 220ca5ebd5..45a36f93d3 100644
--- a/examples/declarative-location/flickr/qmllocationflickr.cpp
+++ b/examples/declarative-location/flickr/qmllocationflickr.cpp
@@ -52,11 +52,11 @@ int main(int argc, char *argv[])
// Qt.quit() called in embedded .qml by default only emits
// quit() signal, so do this (optionally use Qt.exit()).
QObject::connect(view.engine(), SIGNAL(quit()), qApp, SLOT(quit()));
-#if defined(Q_OS_SYMBIAN)
+#if defined(Q_OS_SYMBIAN) || defined(Q_WS_MAEMO_6)
view.showFullScreen();
-#else // Q_OS_SYMBIAN
+#else
view.setGeometry(QRect(100, 100, 360, 640));
view.show();
-#endif // Q_OS_SYMBIAN
+#endif
return application.exec();
}
diff --git a/examples/declarative-location/landmarkmap/qmllandmarkmap.cpp b/examples/declarative-location/landmarkmap/qmllandmarkmap.cpp
index 26229a35c8..391eabb8e5 100644
--- a/examples/declarative-location/landmarkmap/qmllandmarkmap.cpp
+++ b/examples/declarative-location/landmarkmap/qmllandmarkmap.cpp
@@ -52,11 +52,11 @@ int main(int argc, char *argv[])
// Qt.quit() called in embedded .qml by default only emits
// quit() signal, so do this (optionally use Qt.exit()).
QObject::connect(view.engine(), SIGNAL(quit()), qApp, SLOT(quit()));
-#if defined(Q_OS_SYMBIAN)
+#if defined(Q_OS_SYMBIAN) || defined(Q_WS_MAEMO_6)
view.showFullScreen();
-#else // Q_OS_SYMBIAN
+#else
view.setGeometry(QRect(100, 100, 360, 640));
view.show();
-#endif // Q_OS_SYMBIAN
+#endif
return application.exec();
}
diff --git a/examples/declarative-location/mapviewer/qmlmapviewer.cpp b/examples/declarative-location/mapviewer/qmlmapviewer.cpp
index c74e1289aa..f68cf1a070 100644
--- a/examples/declarative-location/mapviewer/qmlmapviewer.cpp
+++ b/examples/declarative-location/mapviewer/qmlmapviewer.cpp
@@ -52,11 +52,11 @@ int main(int argc, char *argv[])
// Qt.quit() called in embedded .qml by default only emits
// quit() signal, so do this (optionally use Qt.exit()).
QObject::connect(view.engine(), SIGNAL(quit()), qApp, SLOT(quit()));
-#if defined(Q_OS_SYMBIAN)
+#if defined(Q_OS_SYMBIAN) || defined(Q_WS_MAEMO_6)
view.showFullScreen();
-#else // Q_OS_SYMBIAN
+#else
view.setGeometry(QRect(100, 100, 360, 640));
view.show();
-#endif // Q_OS_SYMBIAN
+#endif
return application.exec();
}
diff --git a/src/s60installs/deviceconfiguration/mobilityconfig.prf b/src/s60installs/deviceconfiguration/mobilityconfig.prf
deleted file mode 100644
index 91a50cf962..0000000000
--- a/src/s60installs/deviceconfiguration/mobilityconfig.prf
+++ /dev/null
@@ -1,5 +0,0 @@
-MOBILITY_CONFIG=bearer location contacts systeminfo publishsubscribe versit messaging sensors serviceframework multimedia gallery organizer feedback connectivity
-MOBILITY_VERSION = 1.2.0
-MOBILITY_MAJOR_VERSION = 1
-MOBILITY_MINOR_VERSION = 2
-MOBILITY_PATCH_VERSION = 0
diff --git a/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp b/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
index e696cba0c1..fc8aac0b56 100644
--- a/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
+++ b/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
@@ -349,8 +349,11 @@ void TestQGeoPositionInfoSource::setUpdateInterval_data()
int minUpdateInterval = source ? source->minimumUpdateInterval() : -1;
if (source)
delete source;
-
+#if defined(Q_WS_MAEMO_6)
+ QTest::newRow("0") << 0 << minUpdateInterval;
+#else
QTest::newRow("0") << 0 << 0;
+#endif
if (minUpdateInterval > -1) {
QTest::newRow("INT_MIN") << INT_MIN << minUpdateInterval;
@@ -477,7 +480,9 @@ void TestQGeoPositionInfoSource::minimumUpdateInterval()
void TestQGeoPositionInfoSource::startUpdates_testIntervals()
{
CHECK_SOURCE_VALID;
-
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
m_source->setUpdateInterval(7000);
@@ -509,6 +514,9 @@ void TestQGeoPositionInfoSource::startUpdates_testIntervalChangesWhileRunning()
// this test are as high as they are.
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
@@ -565,6 +573,9 @@ void TestQGeoPositionInfoSource::startUpdates_testIntervalChangesWhileRunning()
void TestQGeoPositionInfoSource::startUpdates_testDefaultInterval()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
@@ -582,6 +593,9 @@ void TestQGeoPositionInfoSource::startUpdates_testDefaultInterval()
void TestQGeoPositionInfoSource::startUpdates_testZeroInterval()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
@@ -599,6 +613,9 @@ void TestQGeoPositionInfoSource::startUpdates_testZeroInterval()
void TestQGeoPositionInfoSource::startUpdates_moreThanOnce()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
@@ -620,6 +637,9 @@ void TestQGeoPositionInfoSource::startUpdates_moreThanOnce()
void TestQGeoPositionInfoSource::stopUpdates()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spy(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy timeout(m_source, SIGNAL(updateTimeout()));
@@ -652,6 +672,9 @@ void TestQGeoPositionInfoSource::stopUpdates_withoutStart()
void TestQGeoPositionInfoSource::requestUpdate()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QFETCH(int, timeout);
QSignalSpy spy(m_source, SIGNAL(updateTimeout()));
m_source->requestUpdate(timeout);
@@ -668,6 +691,9 @@ void TestQGeoPositionInfoSource::requestUpdate_data()
void TestQGeoPositionInfoSource::requestUpdate_validTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -682,6 +708,9 @@ void TestQGeoPositionInfoSource::requestUpdate_validTimeout()
void TestQGeoPositionInfoSource::requestUpdate_defaultTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -712,6 +741,9 @@ void TestQGeoPositionInfoSource::requestUpdate_timeoutLessThanMinimumInterval()
void TestQGeoPositionInfoSource::requestUpdate_repeatedCalls()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -732,6 +764,9 @@ void TestQGeoPositionInfoSource::requestUpdate_repeatedCalls()
void TestQGeoPositionInfoSource::requestUpdate_overlappingCalls()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -748,6 +783,9 @@ void TestQGeoPositionInfoSource::requestUpdate_overlappingCalls()
void TestQGeoPositionInfoSource::requestUpdateAfterStartUpdates_ZeroInterval()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -778,6 +816,9 @@ void TestQGeoPositionInfoSource::requestUpdateAfterStartUpdates_ZeroInterval()
void TestQGeoPositionInfoSource::requestUpdateAfterStartUpdates_SmallInterval()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -807,6 +848,9 @@ void TestQGeoPositionInfoSource::requestUpdateAfterStartUpdates_SmallInterval()
void TestQGeoPositionInfoSource::requestUpdateBeforeStartUpdates_ZeroInterval()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -833,7 +877,9 @@ void TestQGeoPositionInfoSource::requestUpdateBeforeStartUpdates_ZeroInterval()
void TestQGeoPositionInfoSource::requestUpdateBeforeStartUpdates_SmallInterval()
{
CHECK_SOURCE_VALID;
-
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyUpdate(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo&)));
QSignalSpy spyTimeout(m_source, SIGNAL(updateTimeout()));
@@ -857,6 +903,9 @@ void TestQGeoPositionInfoSource::requestUpdateBeforeStartUpdates_SmallInterval()
void TestQGeoPositionInfoSource::removeSlotForRequestTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
bool i = connect(m_source, SIGNAL(updateTimeout()), this, SLOT(test_slot1()));
QVERIFY(i == true);
@@ -872,6 +921,9 @@ void TestQGeoPositionInfoSource::removeSlotForRequestTimeout()
void TestQGeoPositionInfoSource::removeSlotForPositionUpdated()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
bool i = connect(m_source, SIGNAL(positionUpdated(const QGeoPositionInfo &)), this, SLOT(test_slot1()));
QVERIFY(i == true);
diff --git a/tests/auto/qgeosatelliteinfosource/testqgeosatelliteinfosource.cpp b/tests/auto/qgeosatelliteinfosource/testqgeosatelliteinfosource.cpp
index 811dac55a1..343a0b0730 100644
--- a/tests/auto/qgeosatelliteinfosource/testqgeosatelliteinfosource.cpp
+++ b/tests/auto/qgeosatelliteinfosource/testqgeosatelliteinfosource.cpp
@@ -512,7 +512,9 @@ void TestQGeoSatelliteInfoSource::startUpdates()
{
CHECK_SOURCE_VALID;
-
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
QSignalSpy spyUse(m_source,
@@ -535,7 +537,9 @@ void TestQGeoSatelliteInfoSource::startUpdates()
void TestQGeoSatelliteInfoSource::startUpdates_moreThanOnce()
{
CHECK_SOURCE_VALID;
-
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
QSignalSpy spyUse(m_source,
@@ -558,6 +562,9 @@ void TestQGeoSatelliteInfoSource::stopUpdates()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -590,6 +597,9 @@ void TestQGeoSatelliteInfoSource::stopUpdates_withoutStart()
void TestQGeoSatelliteInfoSource::requestUpdate()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QFETCH(int, timeout);
QSignalSpy spy(m_source, SIGNAL(requestTimeout()));
@@ -610,6 +620,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_data()
void TestQGeoSatelliteInfoSource::requestUpdate_validTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -628,6 +641,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_validTimeout()
void TestQGeoSatelliteInfoSource::requestUpdate_defaultTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -647,6 +663,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_defaultTimeout()
void TestQGeoSatelliteInfoSource::requestUpdate_repeatedCalls()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -671,6 +690,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_repeatedCalls()
void TestQGeoSatelliteInfoSource::requestUpdate_overlappingCalls()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -694,6 +716,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_overlappingCalls()
void TestQGeoSatelliteInfoSource::requestUpdate_overlappingCallsWithTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -721,6 +746,9 @@ void TestQGeoSatelliteInfoSource::requestUpdate_overlappingCallsWithTimeout()
void TestQGeoSatelliteInfoSource::requestUpdateAfterStartUpdates()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -756,6 +784,9 @@ void TestQGeoSatelliteInfoSource::requestUpdateAfterStartUpdates()
void TestQGeoSatelliteInfoSource::requestUpdateBeforeStartUpdates()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
QSignalSpy spyView(m_source,
SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)));
@@ -785,6 +816,9 @@ void TestQGeoSatelliteInfoSource::requestUpdateBeforeStartUpdates()
void TestQGeoSatelliteInfoSource::removeSlotForRequestTimeout()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
bool i = connect(m_source, SIGNAL(requestTimeout()), this, SLOT(test_slot1()));
QVERIFY(i==true);
@@ -800,6 +834,9 @@ void TestQGeoSatelliteInfoSource::removeSlotForRequestTimeout()
void TestQGeoSatelliteInfoSource::removeSlotForSatellitesInUseUpdated()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
bool i = connect(m_source, SIGNAL(satellitesInUseUpdated(const QList<QGeoSatelliteInfo> &)), this, SLOT(test_slot1()));
QVERIFY(i == true);
@@ -818,6 +855,9 @@ void TestQGeoSatelliteInfoSource::removeSlotForSatellitesInUseUpdated()
void TestQGeoSatelliteInfoSource::removeSlotForSatellitesInViewUpdated()
{
CHECK_SOURCE_VALID;
+#if defined(Q_WS_MAEMO_6)
+ QSKIP("Real GPS not suitable for autotesting, skipping the test.", SkipAll);
+#endif
bool i = connect(m_source, SIGNAL(satellitesInViewUpdated(const QList<QGeoSatelliteInfo> &)), this, SLOT(test_slot1()));
QVERIFY(i == true);