summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorasanoaozora <fifitaneki@hotmail.com>2017-07-04 17:46:17 +0200
committerasanoaozora <fifitaneki@hotmail.com>2017-07-04 17:46:17 +0200
commitafa5a4f857628684d39de2618894f423dd1af5c2 (patch)
tree82f0443623bca944c8ee87412d7a9779637da302 /test
parent4c3e24b04f8ff1e41a94f1c1dd181ae3412c3db9 (diff)
downloadpoi-service-afa5a4f857628684d39de2618894f423dd1af5c2.tar.gz
add DLT to several plugins, allow case insensitive search
Diffstat (limited to 'test')
-rwxr-xr-xtest/navigation/script/test-guidance.py11
-rwxr-xr-xtest/navigation/script/test-poi.py2
-rw-r--r--test/poi-service/script/create-scheme.sql6
3 files changed, 13 insertions, 6 deletions
diff --git a/test/navigation/script/test-guidance.py b/test/navigation/script/test-guidance.py
index 8f91a77..81a3ce5 100755
--- a/test/navigation/script/test-guidance.py
+++ b/test/navigation/script/test-guidance.py
@@ -48,12 +48,13 @@ except dltTriggerNotBuilt:
test_name = "guidance"
#constants used into the script
-TIME_OUT = 10000
+TIME_OUT = 20000
HORIZONTAL_SIZE = 800
VERTICAL_SIZE = 480
MAIN_MAP = 0x0010
NUMBER_OF_SEGMENTS = 500
ZOOM_GUIDANCE = 2
+NUMBER_OF_MANEUVERS_BEFORE_STOP = 5
#add signal receivers
def routing_routeCalculationProgressUpdate_handler(routeHandle, status, percentage):
@@ -120,14 +121,17 @@ def guidance_positionOnRouteChanged_handler(offsetOnRoute):
print ("Offset on route: " +str(offsetOnRoute))
def guidance_maneuverChanged_handler(maneuver):
+ global g_amount_of_maneuvers
print ("Maneuver: " +str(maneuver))
ret = g_guidance_interface.GetDestinationInformation()
print ("Travel time: " +str(ret[1]))
ret = g_guidance_interface.GetManeuversList(dbus.UInt16(10),dbus.UInt32(0))
print ("Number of maneuvers: " +str(ret[1]))
print ("Next road to turn: " +str(ret[2][0][4]))
- g_mapmatchedposition_interface.SetSimulationMode(dbus.UInt32(g_navigationcore_session_handle),dbus.Boolean(False))
- g_guidance_interface.StopGuidance(dbus.UInt32(g_navigationcore_session_handle))
+ g_amount_of_maneuvers += 1
+ if g_amount_of_maneuvers > NUMBER_OF_MANEUVERS_BEFORE_STOP:
+ g_mapmatchedposition_interface.SetSimulationMode(dbus.UInt32(g_navigationcore_session_handle),dbus.Boolean(False))
+ g_guidance_interface.StopGuidance(dbus.UInt32(g_navigationcore_session_handle))
def mapmatchedposition_simulationStatusChanged_handler(simulationStatus):
print ("Simulation status: " +str(simulationStatus))
@@ -337,6 +341,7 @@ createMapView()
g_current_route = 0
g_guidance_active = False
+g_amount_of_maneuvers = 0
launch_route_calculation(0)
#main loop
diff --git a/test/navigation/script/test-poi.py b/test/navigation/script/test-poi.py
index 6610a48..7192308 100755
--- a/test/navigation/script/test-poi.py
+++ b/test/navigation/script/test-poi.py
@@ -55,7 +55,7 @@ ATTRIBUTE_SOURCE = 0
ATTRIBUTE_PHONE = 2
RADIUS_HOTEL = 100 #in tenth of meter !
RADIUS_RESTAURANT = 500
-STRING_TO_SEARCH = "hof"
+STRING_TO_SEARCH = "ZUm"
MAX_WINDOW_SIZE = 100
OFFSET = 0
diff --git a/test/poi-service/script/create-scheme.sql b/test/poi-service/script/create-scheme.sql
index 154f550..fe20826 100644
--- a/test/poi-service/script/create-scheme.sql
+++ b/test/poi-service/script/create-scheme.sql
@@ -1,6 +1,6 @@
/**
* @licence app begin@
- * Copyright (C) 2011-2012 PCA Peugeot Citroën
+ * Copyright (C) 2017 PSA GROUP
*
* This file is part of GENIVI Project POISearch Proof Of Concept [POIPOCSupplier].
*
@@ -18,6 +18,8 @@
* Modifications:
* 19-12-2013 Philippe Colliot
* add new fields to poi (brand and operateur)
+ * 04-07-2017 Philippe Colliot
+ * add COLLATE NOCASE to poi name
*
* For further information see http://www.genivi.org/.
* @licence end@
@@ -52,7 +54,7 @@ CREATE TABLE poiattribute (
DROP TABLE IF EXISTS poi;
CREATE TABLE poi (
Id int NOT NULL,
- name text UNIQUE,
+ name text UNIQUE COLLATE NOCASE,
latitude double DEFAULT NULL,
longitude double DEFAULT NULL,
altitude int DEFAULT NULL,