summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-03-10 10:27:14 +0100
committerLiang Qi <liang.qi@qt.io>2017-03-10 10:27:14 +0100
commitdca175454aefdd019952d941c6369c314e8c3b11 (patch)
tree82e11b9e741ba07a7a32377048f1eb823ea76903 /tests
parent495ea425b376f5b6d65a078c4699e4b7b60a145f (diff)
parent31ff679359172dfa068014ab0537418f5b852eac (diff)
downloadqtlocation-dca175454aefdd019952d941c6369c314e8c3b11.tar.gz
Merge remote-tracking branch 'origin/5.8' into 5.9
Change-Id: Ibd6d68ced4edbd96fb67fe61244b83d597df5775
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/declarative_core/main.cpp2
-rw-r--r--tests/auto/declarative_ui/main.cpp2
-rw-r--r--tests/auto/nokia_services/places_semiauto/tst_places.cpp4
-rw-r--r--tests/auto/positionplugintest/tst_positionplugin.cpp2
-rw-r--r--tests/auto/qgeoareamonitor/tst_qgeoareamonitor.cpp2
-rw-r--r--tests/auto/qgeocodingmanager/tst_qgeocodingmanager.cpp2
-rw-r--r--tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp2
-rw-r--r--tests/auto/qgeoroutingmanager/tst_qgeoroutingmanager.cpp2
-rw-r--r--tests/auto/qgeoserviceprovider/tst_qgeoserviceprovider.cpp2
-rw-r--r--tests/auto/qgeotiledmap/tst_qgeotiledmap.cpp2
-rw-r--r--tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_realtime_generic/tst_qnmeapositioninfosource_realtime_generic.cpp2
-rw-r--r--tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_simulation_generic/tst_qnmeapositioninfosource_simulation_generic.cpp2
-rw-r--r--tests/auto/qplacemanager/tst_qplacemanager.cpp2
-rw-r--r--tests/auto/qplacemanager_unsupported/tst_qplacemanager_unsupported.cpp2
14 files changed, 29 insertions, 1 deletions
diff --git a/tests/auto/declarative_core/main.cpp b/tests/auto/declarative_core/main.cpp
index 041dbb7e..b380a231 100644
--- a/tests/auto/declarative_core/main.cpp
+++ b/tests/auto/declarative_core/main.cpp
@@ -31,6 +31,7 @@
static void initializeLibraryPath()
{
+#if QT_CONFIG(library)
// Set custom path since CI doesn't install test plugins
#ifdef Q_OS_WIN
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
@@ -39,6 +40,7 @@ static void initializeLibraryPath()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
QStringLiteral("/../../../plugins"));
#endif
+#endif
}
Q_COREAPP_STARTUP_FUNCTION(initializeLibraryPath)
diff --git a/tests/auto/declarative_ui/main.cpp b/tests/auto/declarative_ui/main.cpp
index 8a12f411..49e64bc0 100644
--- a/tests/auto/declarative_ui/main.cpp
+++ b/tests/auto/declarative_ui/main.cpp
@@ -31,6 +31,7 @@
static void initializeLibraryPath()
{
+#if QT_CONFIG(library)
// Set custom path since CI doesn't install test plugins
#ifdef Q_OS_WIN
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
@@ -39,6 +40,7 @@ static void initializeLibraryPath()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
QStringLiteral("/../../../plugins"));
#endif
+#endif
}
Q_COREAPP_STARTUP_FUNCTION(initializeLibraryPath)
diff --git a/tests/auto/nokia_services/places_semiauto/tst_places.cpp b/tests/auto/nokia_services/places_semiauto/tst_places.cpp
index 8e5289d4..2f68ab44 100644
--- a/tests/auto/nokia_services/places_semiauto/tst_places.cpp
+++ b/tests/auto/nokia_services/places_semiauto/tst_places.cpp
@@ -30,7 +30,9 @@
#include <QString>
#include <QtTest/QtTest>
+#if QT_CONFIG(process)
#include <QtCore/QProcessEnvironment>
+#endif
#include <QtPositioning/QGeoCircle>
#include <QtLocation/QGeoServiceProvider>
#include <QtLocation/QPlaceEditorial>
@@ -105,7 +107,7 @@ void tst_QPlaceManagerNokia::initTestCase()
QVariantMap params;
QStringList providers = QGeoServiceProvider::availableServiceProviders();
QVERIFY(providers.contains("here"));
-#ifndef QT_NO_PROCESS
+#if QT_CONFIG(process)
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
if (!(env.contains(AppIdEnv) && env.contains(TokenEnv)))
diff --git a/tests/auto/positionplugintest/tst_positionplugin.cpp b/tests/auto/positionplugintest/tst_positionplugin.cpp
index 34d05094..6e8847b8 100644
--- a/tests/auto/positionplugintest/tst_positionplugin.cpp
+++ b/tests/auto/positionplugintest/tst_positionplugin.cpp
@@ -53,6 +53,7 @@ private slots:
void tst_PositionPlugin::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -63,6 +64,7 @@ void tst_PositionPlugin::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
qRegisterMetaType<QGeoPositionInfo>();
}
diff --git a/tests/auto/qgeoareamonitor/tst_qgeoareamonitor.cpp b/tests/auto/qgeoareamonitor/tst_qgeoareamonitor.cpp
index 55261984..75c1eecb 100644
--- a/tests/auto/qgeoareamonitor/tst_qgeoareamonitor.cpp
+++ b/tests/auto/qgeoareamonitor/tst_qgeoareamonitor.cpp
@@ -77,6 +77,7 @@ class tst_QGeoAreaMonitorSource : public QObject
private slots:
void initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install plugins
*/
@@ -87,6 +88,7 @@ private slots:
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
qRegisterMetaType<QGeoPositionInfo>();
qRegisterMetaType<QGeoAreaMonitorInfo>();
}
diff --git a/tests/auto/qgeocodingmanager/tst_qgeocodingmanager.cpp b/tests/auto/qgeocodingmanager/tst_qgeocodingmanager.cpp
index 581b3c4e..9647c0d6 100644
--- a/tests/auto/qgeocodingmanager/tst_qgeocodingmanager.cpp
+++ b/tests/auto/qgeocodingmanager/tst_qgeocodingmanager.cpp
@@ -35,6 +35,7 @@ QT_USE_NAMESPACE
void tst_QGeoCodingManager::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -45,6 +46,7 @@ void tst_QGeoCodingManager::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
tst_QGeoCodingManager::loadGeocodingManager();
}
diff --git a/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp b/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
index 31ab86f3..0fc8f492 100644
--- a/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
+++ b/tests/auto/qgeopositioninfosource/testqgeopositioninfosource.cpp
@@ -109,6 +109,7 @@ TestQGeoPositionInfoSource::TestQGeoPositionInfoSource(QObject *parent)
: QObject(parent)
{
m_testingDefaultSource = false;
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -119,6 +120,7 @@ TestQGeoPositionInfoSource::TestQGeoPositionInfoSource(QObject *parent)
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
}
TestQGeoPositionInfoSource *TestQGeoPositionInfoSource::createDefaultSourceTest()
diff --git a/tests/auto/qgeoroutingmanager/tst_qgeoroutingmanager.cpp b/tests/auto/qgeoroutingmanager/tst_qgeoroutingmanager.cpp
index 4dbeea55..dc519b48 100644
--- a/tests/auto/qgeoroutingmanager/tst_qgeoroutingmanager.cpp
+++ b/tests/auto/qgeoroutingmanager/tst_qgeoroutingmanager.cpp
@@ -35,6 +35,7 @@ QT_USE_NAMESPACE
void tst_QGeoRoutingManager::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -45,6 +46,7 @@ void tst_QGeoRoutingManager::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
tst_QGeoRoutingManager::loadRoutingManager();
}
diff --git a/tests/auto/qgeoserviceprovider/tst_qgeoserviceprovider.cpp b/tests/auto/qgeoserviceprovider/tst_qgeoserviceprovider.cpp
index 6a9457fe..6efa2f92 100644
--- a/tests/auto/qgeoserviceprovider/tst_qgeoserviceprovider.cpp
+++ b/tests/auto/qgeoserviceprovider/tst_qgeoserviceprovider.cpp
@@ -48,6 +48,7 @@ private slots:
void tst_QGeoServiceProvider::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -58,6 +59,7 @@ void tst_QGeoServiceProvider::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
}
void tst_QGeoServiceProvider::tst_availableServiceProvider()
diff --git a/tests/auto/qgeotiledmap/tst_qgeotiledmap.cpp b/tests/auto/qgeotiledmap/tst_qgeotiledmap.cpp
index 22fb6589..ae0083ba 100644
--- a/tests/auto/qgeotiledmap/tst_qgeotiledmap.cpp
+++ b/tests/auto/qgeotiledmap/tst_qgeotiledmap.cpp
@@ -92,6 +92,7 @@ tst_QGeoTiledMap::~tst_QGeoTiledMap()
void tst_QGeoTiledMap::initTestCase()
{
+#if QT_CONFIG(library)
// Set custom path since CI doesn't install test plugins
#ifdef Q_OS_WIN
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
@@ -100,6 +101,7 @@ void tst_QGeoTiledMap::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath() +
QStringLiteral("/../../../plugins"));
#endif
+#endif
QVariantMap parameters;
parameters["tileSize"] = 256;
parameters["maxZoomLevel"] = 8;
diff --git a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_realtime_generic/tst_qnmeapositioninfosource_realtime_generic.cpp b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_realtime_generic/tst_qnmeapositioninfosource_realtime_generic.cpp
index cedcd56a..d3f03c0d 100644
--- a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_realtime_generic/tst_qnmeapositioninfosource_realtime_generic.cpp
+++ b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_realtime_generic/tst_qnmeapositioninfosource_realtime_generic.cpp
@@ -38,6 +38,7 @@ public:
tst_QNmeaPositionInfoSource_RealTime_Generic()
{
m_factory = new QNmeaPositionInfoSourceProxyFactory;
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -48,6 +49,7 @@ public:
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../../plugins"));
#endif
+#endif
}
~tst_QNmeaPositionInfoSource_RealTime_Generic()
diff --git a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_simulation_generic/tst_qnmeapositioninfosource_simulation_generic.cpp b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_simulation_generic/tst_qnmeapositioninfosource_simulation_generic.cpp
index 0d8f03c9..adc55f64 100644
--- a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_simulation_generic/tst_qnmeapositioninfosource_simulation_generic.cpp
+++ b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosource_simulation_generic/tst_qnmeapositioninfosource_simulation_generic.cpp
@@ -36,6 +36,7 @@ class tst_QNmeaPositionInfoSource_Simulation_Generic : public TestQGeoPositionIn
public:
tst_QNmeaPositionInfoSource_Simulation_Generic()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -46,6 +47,7 @@ public:
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../../plugins"));
#endif
+#endif
}
protected:
diff --git a/tests/auto/qplacemanager/tst_qplacemanager.cpp b/tests/auto/qplacemanager/tst_qplacemanager.cpp
index fe97b37c..2cb035cd 100644
--- a/tests/auto/qplacemanager/tst_qplacemanager.cpp
+++ b/tests/auto/qplacemanager/tst_qplacemanager.cpp
@@ -72,6 +72,7 @@ private:
void tst_QPlaceManager::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -82,6 +83,7 @@ void tst_QPlaceManager::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
provider = 0;
QStringList providers = QGeoServiceProvider::availableServiceProviders();
diff --git a/tests/auto/qplacemanager_unsupported/tst_qplacemanager_unsupported.cpp b/tests/auto/qplacemanager_unsupported/tst_qplacemanager_unsupported.cpp
index 41716103..98a9dd31 100644
--- a/tests/auto/qplacemanager_unsupported/tst_qplacemanager_unsupported.cpp
+++ b/tests/auto/qplacemanager_unsupported/tst_qplacemanager_unsupported.cpp
@@ -75,6 +75,7 @@ private:
void tst_QPlaceManagerUnsupported::initTestCase()
{
+#if QT_CONFIG(library)
/*
* Set custom path since CI doesn't install test plugins
*/
@@ -85,6 +86,7 @@ void tst_QPlaceManagerUnsupported::initTestCase()
QCoreApplication::addLibraryPath(QCoreApplication::applicationDirPath()
+ QStringLiteral("/../../../plugins"));
#endif
+#endif
m_provider = 0;
m_manager = 0;