summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
author <philippe colliot>2016-02-16 14:07:44 +0100
committer <philippe colliot>2016-02-16 14:07:44 +0100
commit69f9de871a7d45952806e81b7b8baba6f3808a7e (patch)
tree6f8552e3371d9d10f11f5b0516f93ba5abe60ac2 /test
parent1a7250d57aa590f1a06e3cbd6127663855652d68 (diff)
downloadpoi-service-69f9de871a7d45952806e81b7b8baba6f3808a7e.tar.gz
fix dbus issue with poi interface, update scripts
Diffstat (limited to 'test')
-rw-r--r--test/poi-service/poi-manager-client/main.cpp9
-rwxr-xr-xtest/poi-service/rebuild_all.sh36
2 files changed, 33 insertions, 12 deletions
diff --git a/test/poi-service/poi-manager-client/main.cpp b/test/poi-service/poi-manager-client/main.cpp
index e64d4f5..8decba0 100644
--- a/test/poi-service/poi-manager-client/main.cpp
+++ b/test/poi-service/poi-manager-client/main.cpp
@@ -408,8 +408,15 @@ void contentManager::testSearch()
categoryAndRadius.setRadius(SEARCH_RADIUS);
poiCategories.push_back(categoryAndRadius);
- attributeDetails.setCategoryId(m_category_id);
attributeDetails.setId(ATTRIBUTE_ADDRCITY);
+ attributeDetails.setCategoryId(m_category_id);
+ attributeDetails.setType(POIServiceTypes::AttributeType::BOOLEAN);
+ POIServiceTypes::AttributeValue v(NEW_STARS_VALUE);
+ attributeDetails.setValue(v);
+ attributeDetails.setOper(POIServiceTypes::OperatorType::EQUAL);
+ attributeDetails.setMandatory(FALSE);
+
+ poiAttributes.clear();
poiAttributes.push_back(attributeDetails);
mp_proxy->poiSearchStarted(SEARCH_HANDLE,SEARCH_MAX_SIZE,location,poiCategories,poiAttributes,SEARCH_STRING,POIServiceTypes::SortOption::ATTRIBUTE_CUSTOM,status);
diff --git a/test/poi-service/rebuild_all.sh b/test/poi-service/rebuild_all.sh
index fc02261..828b2d6 100755
--- a/test/poi-service/rebuild_all.sh
+++ b/test/poi-service/rebuild_all.sh
@@ -4,10 +4,14 @@ debug="OFF"
franca="OFF"
dbus="ON"
commonapi_tools_option=""
+clean=0
-while getopts df opt
+while getopts cdf opt
do
case $opt in
+ c)
+ clean=1
+ ;;
d)
debug="ON"
;;
@@ -17,7 +21,8 @@ do
;;
\?)
echo "Usage:"
- echo "$0 [-df]"
+ echo "$0 [-cdf]"
+ echo "-c: Rebuild with clean"
echo "-d: Enable the debug messages"
echo "-f: Build using the Franca interfaces"
exit 1
@@ -52,19 +57,22 @@ then
fi
-echo 'build the poi server'
cd ../../src/poi-service
./rebuild_all.sh "$@"
cd ../../test/poi-service
-echo 'build the poi client'
-
-echo 'clean up the build folder'
-if [ -d "./build" ]
+if [ "$clean" = 1 ]
then
- find ./build ! -name '*.cbp' -type f -exec rm -f {} +
+ echo 'clean up the build folder'
+ if [ -d "./build" ]
+ then
+ find ./build ! -name '*.cbp' -type f -exec rm -f {} +
+ fi
+else
+ echo 'just build without generation of the database'
fi
+
mkdir -p build
cd build
@@ -72,12 +80,18 @@ cd build
echo 'build poi-client'
# Important notice: for the time being, it's just poi manager client that can be built against common api,
# so it's needed to set WITH_DBUS_INTERFACE=ON for positioning
-cmake -DWITH_DATABASE_SUPPLIER=ON -DWITH_FRANCA_DBUS_INTERFACE=$franca -DWITH_DBUS_INTERFACE=ON $commonapi_tools_option -DWITH_DEBUG=$debug ../
+if [ "$clean" = 1 ]
+then
+ cmake -DWITH_DATABASE_SUPPLIER=ON -DWITH_FRANCA_DBUS_INTERFACE=$franca -DWITH_DBUS_INTERFACE=ON $commonapi_tools_option -DWITH_DEBUG=$debug ../
+fi
make
cd ..
-echo 'populate the database with POIs of Paris'
-./prepare -c paris
+if [ "$clean" = 1 ]
+then
+ echo 'populate the database with POIs of Paris'
+ ./prepare -c paris
+fi