[UTC][capi-maps-service][Non-ACR][improvement line coverage rate]
authorchanywa <cbible.kim@samsung.com>
Tue, 12 Jul 2016 03:38:16 +0000 (12:38 +0900)
committerchanywa <cbible.kim@samsung.com>
Tue, 12 Jul 2016 03:38:16 +0000 (12:38 +0900)
Change-Id: I545c7cf97e6380b885113270efc395ed166d60a3

src/utc/capi-maps-service/tct-capi-maps-service-core_mobile.h
src/utc/capi-maps-service/tct-capi-maps-service-core_wearable.h
src/utc/capi-maps-service/utc_maps_service.c
src/utc/capi-maps-service/utc_maps_view.c
src/utc/capi-maps-service/utc_maps_view_object.c

index 2a9303f..00faf08 100755 (executable)
@@ -63,6 +63,8 @@ extern void utc_maps_view_event_data_startup(void);
 extern void utc_maps_view_event_data_cleanup(void);
 extern void utc_maps_view_object_startup(void);
 extern void utc_maps_view_object_cleanup(void);
+extern void utc_maps_view_object_overlay_startup(void);
+extern void utc_maps_view_object_overlay_cleanup(void);
 extern void utc_maps_view_startup(void);
 extern void utc_maps_view_cleanup(void);
 
@@ -552,6 +554,7 @@ extern int utc_maps_view_set_scalebar_enabled_n(void);
 extern int utc_maps_view_get_scalebar_enabled_p(void);
 extern int utc_maps_view_get_scalebar_enabled_n(void);
 extern int utc_maps_view_add_object_p(void);
+extern int utc_maps_view_add_object_p2(void);
 extern int utc_maps_view_add_object_n(void);
 extern int utc_maps_view_remove_object_p(void);
 extern int utc_maps_view_remove_object_n(void);
@@ -970,22 +973,22 @@ testcase tc_array[] = {
     {"utc_maps_view_object_polygon_set_fill_color_n", utc_maps_view_object_polygon_set_fill_color_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
     {"utc_maps_view_object_polygon_get_fill_color_p", utc_maps_view_object_polygon_get_fill_color_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
     {"utc_maps_view_object_polygon_get_fill_color_n", utc_maps_view_object_polygon_get_fill_color_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_create_overlay_p", utc_maps_view_object_create_overlay_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_create_overlay_n", utc_maps_view_object_create_overlay_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_object_p", utc_maps_view_object_overlay_get_object_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_object_n", utc_maps_view_object_overlay_get_object_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_coordinates_p", utc_maps_view_object_overlay_set_coordinates_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_coordinates_n", utc_maps_view_object_overlay_set_coordinates_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_coordinates_p", utc_maps_view_object_overlay_get_coordinates_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_coordinates_n", utc_maps_view_object_overlay_get_coordinates_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_min_zoom_level_p", utc_maps_view_object_overlay_set_min_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_min_zoom_level_n", utc_maps_view_object_overlay_set_min_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_min_zoom_level_p", utc_maps_view_object_overlay_get_min_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_min_zoom_level_n", utc_maps_view_object_overlay_get_min_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_max_zoom_level_p", utc_maps_view_object_overlay_set_max_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_max_zoom_level_n", utc_maps_view_object_overlay_set_max_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_max_zoom_level_p", utc_maps_view_object_overlay_get_max_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_max_zoom_level_n", utc_maps_view_object_overlay_get_max_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
+    {"utc_maps_view_object_create_overlay_p", utc_maps_view_object_create_overlay_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_create_overlay_n", utc_maps_view_object_create_overlay_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_object_p", utc_maps_view_object_overlay_get_object_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_object_n", utc_maps_view_object_overlay_get_object_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_coordinates_p", utc_maps_view_object_overlay_set_coordinates_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_coordinates_n", utc_maps_view_object_overlay_set_coordinates_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_coordinates_p", utc_maps_view_object_overlay_get_coordinates_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_coordinates_n", utc_maps_view_object_overlay_get_coordinates_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_min_zoom_level_p", utc_maps_view_object_overlay_set_min_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_min_zoom_level_n", utc_maps_view_object_overlay_set_min_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_min_zoom_level_p", utc_maps_view_object_overlay_get_min_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_min_zoom_level_n", utc_maps_view_object_overlay_get_min_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_max_zoom_level_p", utc_maps_view_object_overlay_set_max_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_max_zoom_level_n", utc_maps_view_object_overlay_set_max_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_max_zoom_level_p", utc_maps_view_object_overlay_get_max_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_max_zoom_level_n", utc_maps_view_object_overlay_get_max_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
     {"utc_maps_view_create_p", utc_maps_view_create_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_create_n", utc_maps_view_create_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_get_center_p", utc_maps_view_get_center_p, utc_maps_view_startup, utc_maps_view_cleanup},
@@ -1055,6 +1058,7 @@ testcase tc_array[] = {
     {"utc_maps_view_get_scalebar_enabled_p", utc_maps_view_get_scalebar_enabled_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_get_scalebar_enabled_n", utc_maps_view_get_scalebar_enabled_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_add_object_p", utc_maps_view_add_object_p, utc_maps_view_startup, utc_maps_view_cleanup},
+    {"utc_maps_view_add_object_p2", utc_maps_view_add_object_p2, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_add_object_n", utc_maps_view_add_object_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_remove_object_p", utc_maps_view_remove_object_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_remove_object_n", utc_maps_view_remove_object_n, utc_maps_view_startup, utc_maps_view_cleanup},
index 2a9303f..00faf08 100755 (executable)
@@ -63,6 +63,8 @@ extern void utc_maps_view_event_data_startup(void);
 extern void utc_maps_view_event_data_cleanup(void);
 extern void utc_maps_view_object_startup(void);
 extern void utc_maps_view_object_cleanup(void);
+extern void utc_maps_view_object_overlay_startup(void);
+extern void utc_maps_view_object_overlay_cleanup(void);
 extern void utc_maps_view_startup(void);
 extern void utc_maps_view_cleanup(void);
 
@@ -552,6 +554,7 @@ extern int utc_maps_view_set_scalebar_enabled_n(void);
 extern int utc_maps_view_get_scalebar_enabled_p(void);
 extern int utc_maps_view_get_scalebar_enabled_n(void);
 extern int utc_maps_view_add_object_p(void);
+extern int utc_maps_view_add_object_p2(void);
 extern int utc_maps_view_add_object_n(void);
 extern int utc_maps_view_remove_object_p(void);
 extern int utc_maps_view_remove_object_n(void);
@@ -970,22 +973,22 @@ testcase tc_array[] = {
     {"utc_maps_view_object_polygon_set_fill_color_n", utc_maps_view_object_polygon_set_fill_color_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
     {"utc_maps_view_object_polygon_get_fill_color_p", utc_maps_view_object_polygon_get_fill_color_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
     {"utc_maps_view_object_polygon_get_fill_color_n", utc_maps_view_object_polygon_get_fill_color_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_create_overlay_p", utc_maps_view_object_create_overlay_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_create_overlay_n", utc_maps_view_object_create_overlay_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_object_p", utc_maps_view_object_overlay_get_object_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_object_n", utc_maps_view_object_overlay_get_object_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_coordinates_p", utc_maps_view_object_overlay_set_coordinates_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_coordinates_n", utc_maps_view_object_overlay_set_coordinates_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_coordinates_p", utc_maps_view_object_overlay_get_coordinates_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_coordinates_n", utc_maps_view_object_overlay_get_coordinates_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_min_zoom_level_p", utc_maps_view_object_overlay_set_min_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_min_zoom_level_n", utc_maps_view_object_overlay_set_min_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_min_zoom_level_p", utc_maps_view_object_overlay_get_min_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_min_zoom_level_n", utc_maps_view_object_overlay_get_min_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_max_zoom_level_p", utc_maps_view_object_overlay_set_max_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_set_max_zoom_level_n", utc_maps_view_object_overlay_set_max_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_max_zoom_level_p", utc_maps_view_object_overlay_get_max_zoom_level_p, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
-    {"utc_maps_view_object_overlay_get_max_zoom_level_n", utc_maps_view_object_overlay_get_max_zoom_level_n, utc_maps_view_object_startup, utc_maps_view_object_cleanup},
+    {"utc_maps_view_object_create_overlay_p", utc_maps_view_object_create_overlay_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_create_overlay_n", utc_maps_view_object_create_overlay_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_object_p", utc_maps_view_object_overlay_get_object_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_object_n", utc_maps_view_object_overlay_get_object_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_coordinates_p", utc_maps_view_object_overlay_set_coordinates_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_coordinates_n", utc_maps_view_object_overlay_set_coordinates_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_coordinates_p", utc_maps_view_object_overlay_get_coordinates_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_coordinates_n", utc_maps_view_object_overlay_get_coordinates_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_min_zoom_level_p", utc_maps_view_object_overlay_set_min_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_min_zoom_level_n", utc_maps_view_object_overlay_set_min_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_min_zoom_level_p", utc_maps_view_object_overlay_get_min_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_min_zoom_level_n", utc_maps_view_object_overlay_get_min_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_max_zoom_level_p", utc_maps_view_object_overlay_set_max_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_set_max_zoom_level_n", utc_maps_view_object_overlay_set_max_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_max_zoom_level_p", utc_maps_view_object_overlay_get_max_zoom_level_p, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
+    {"utc_maps_view_object_overlay_get_max_zoom_level_n", utc_maps_view_object_overlay_get_max_zoom_level_n, utc_maps_view_object_overlay_startup, utc_maps_view_object_overlay_cleanup},
     {"utc_maps_view_create_p", utc_maps_view_create_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_create_n", utc_maps_view_create_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_get_center_p", utc_maps_view_get_center_p, utc_maps_view_startup, utc_maps_view_cleanup},
@@ -1055,6 +1058,7 @@ testcase tc_array[] = {
     {"utc_maps_view_get_scalebar_enabled_p", utc_maps_view_get_scalebar_enabled_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_get_scalebar_enabled_n", utc_maps_view_get_scalebar_enabled_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_add_object_p", utc_maps_view_add_object_p, utc_maps_view_startup, utc_maps_view_cleanup},
+    {"utc_maps_view_add_object_p2", utc_maps_view_add_object_p2, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_add_object_n", utc_maps_view_add_object_n, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_remove_object_p", utc_maps_view_remove_object_p, utc_maps_view_startup, utc_maps_view_cleanup},
     {"utc_maps_view_remove_object_n", utc_maps_view_remove_object_n, utc_maps_view_startup, utc_maps_view_cleanup},
index 028808a..93cd5a7 100755 (executable)
@@ -1335,6 +1335,9 @@ int utc_maps_service_multi_reverse_geocode_n(void)
        ret = maps_coordinates_list_append(coordinates_list, coord[0]);
        assert_eq(ret, MAPS_ERROR_NONE);
 
+       ret = maps_service_multi_reverse_geocode(__pMaps, coordinates_list, __preference, __utc_maps_service_multi_reverse_geocode_cb, NULL, &request_id);
+       ASSERT_IF_VAL_REF2(ret, is_internet_supported, MAPS_ERROR_INVALID_PARAMETER, MAPS_ERROR_NOT_SUPPORTED);
+
        ret = maps_coordinates_list_append(coordinates_list, coord[1]);
        assert_eq(ret, MAPS_ERROR_NONE);
 
index b96110b..1de03f5 100755 (executable)
@@ -928,6 +928,9 @@ int utc_maps_view_set_visibility_p(void)
        ret = maps_view_set_visibility(maps_view_handle, false);
        assert_eq(ret, MAPS_ERROR_NONE);
 
+       ret = maps_view_set_visibility(maps_view_handle, true);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
        return 0;
 }
 
@@ -1204,6 +1207,33 @@ int utc_maps_view_add_object_p(void)
 }
 
 /*
+ * @testcase        utc_maps_view_add_object_p2
+ * @since_tizen     @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
+ * @description     Positive test case of maps_view_add_object()
+ */
+int utc_maps_view_add_object_p2(void)
+{
+       Evas_Object *eo = elm_button_add(win);
+       assert(eo);
+
+       maps_coordinates_h coord = NULL;
+       ret = maps_coordinates_create(0.0, 0.0, &coord);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       maps_view_object_h overlay = NULL;
+       ret = maps_view_object_create_overlay(coord, eo, MAPS_VIEW_OVERLAY_BUBBLE, &overlay);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       ret = maps_view_add_object(maps_view_handle, overlay);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       ret = maps_view_remove_object(maps_view_handle, overlay);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       return 0;
+}
+
+/*
  * @testcase        utc_maps_view_add_object_n
  * @since_tizen     @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
  * @description     Negative test case of maps_view_add_object()
@@ -1414,11 +1444,11 @@ int utc_maps_view_set_max_zoom_level_n(void)
  */
 int utc_maps_view_capture_snapshot_p(void)
 {
-       char *path = "/tmp/maps_tmp_image.bmp";
-
-       ret = maps_view_capture_snapshot(maps_view_handle, MAPS_VIEW_SNAPSHOT_BMP, 50, path);
+       ret = maps_view_capture_snapshot(maps_view_handle, MAPS_VIEW_SNAPSHOT_BMP, 90, "/tmp/maps_tmp_image.bmp");
        assert_eq(ret, MAPS_ERROR_NONE);
 
+       ret = maps_view_capture_snapshot(maps_view_handle, MAPS_VIEW_SNAPSHOT_JPEG, 90, "/tmp/maps_tmp_image.jpg");
+       assert_eq(ret, MAPS_ERROR_NONE);
        return 0;
 }
 
index ff032c7..d533b4b 100755 (executable)
@@ -32,6 +32,7 @@
 static Evas_Object *win = NULL;
 static int ret = 0;
 static char image_path[4096] = {0, };
+maps_view_object_h overlay = NULL;
 
 static bool dummy_maps_coordinates_cb(int index, maps_coordinates_h coordinates, void *user_data)
 {
@@ -1433,6 +1434,36 @@ int utc_maps_view_object_polygon_get_fill_color_n(void)
 }
 
 /**
+ * @function           utc_map_view_startup
+ * @description                Called before each test
+ * @parameter          NA
+ * @return             NA
+ */
+void utc_maps_view_object_overlay_startup(void)
+{
+       utc_maps_view_object_startup();
+
+       maps_coordinates_h coordinate = NULL;
+       Evas_Object *object = elm_button_add(win);
+       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
+
+       maps_coordinates_create(0.0, 0.0, &coordinate);
+       maps_view_object_create_overlay(coordinate, object, type, &overlay);
+}
+
+/**
+ * @function           utc_map_view_cleanup
+ * @description                Called after each test
+ * @parameter          NA
+ * @return             NA
+ */
+void utc_maps_view_object_overlay_cleanup(void)
+{
+       maps_view_object_destroy(overlay);
+       utc_maps_view_object_cleanup();
+}
+
+/**
  * @testcase           utc_maps_view_object_create_overlay_p
  * @since_tizen                @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
  * @description                Positive test case of maps_view_object_create_overlay()
@@ -1450,38 +1481,10 @@ int utc_maps_view_object_create_overlay_p(void)
        ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
        assert_eq(ret, MAPS_ERROR_NONE);
 
-       Evas_Object *object_tmp = NULL;
-
-       ret = maps_view_object_overlay_get_object(overlay, &object_tmp);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       maps_coordinates_h coordinate_tmp = NULL;
-
-       ret = maps_coordinates_create(1.0, 1.0, &coordinate_tmp);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_overlay_set_coordinates(overlay, coordinate_tmp);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       coordinate = NULL;
-
-       ret = maps_view_object_overlay_get_coordinates(overlay, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_overlay_set_min_zoom_level(overlay, 1);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       int min_zoom = 0;
-
-       ret = maps_view_object_overlay_get_min_zoom_level(overlay, &min_zoom);
+       ret = maps_view_object_set_visible(overlay, true);
        assert_eq(ret, MAPS_ERROR_NONE);
 
-       ret = maps_view_object_overlay_set_max_zoom_level(overlay, 5);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       int max_zoom = 0;
-
-       ret = maps_view_object_overlay_get_max_zoom_level(overlay, &max_zoom);
+       ret = maps_view_object_set_visible(overlay, false);
        assert_eq(ret, MAPS_ERROR_NONE);
 
        ret = maps_view_object_destroy(overlay);
@@ -1527,7 +1530,10 @@ int utc_maps_view_object_create_overlay_n(void)
  */
 int utc_maps_view_object_overlay_get_object_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       Evas_Object *object = NULL;
+
+       ret = maps_view_object_overlay_get_object(overlay, &object);
+       assert_eq(ret, MAPS_ERROR_NONE);
        return 0;
 }
 
@@ -1538,28 +1544,14 @@ int utc_maps_view_object_overlay_get_object_p(void)
  */
 int utc_maps_view_object_overlay_get_object_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       Evas_Object *object_tmp = NULL;
+       Evas_Object *object = NULL;
 
-       ret = maps_view_object_overlay_get_object(NULL, &object_tmp);
+       ret = maps_view_object_overlay_get_object(NULL, &object);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
        ret = maps_view_object_overlay_get_object(overlay, NULL);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }
 
@@ -1570,7 +1562,12 @@ int utc_maps_view_object_overlay_get_object_n(void)
  */
 int utc_maps_view_object_overlay_set_coordinates_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       maps_coordinates_h coordinates = NULL;
+       ret = maps_coordinates_create(1.0, 1.0, &coordinates);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       ret = maps_view_object_overlay_set_coordinates(overlay, coordinates);
+       assert_eq(ret, MAPS_ERROR_NONE);
        return 0;
 }
 
@@ -1581,32 +1578,18 @@ int utc_maps_view_object_overlay_set_coordinates_p(void)
  */
 int utc_maps_view_object_overlay_set_coordinates_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       maps_coordinates_h coordinate_tmp = NULL;
+       maps_coordinates_h coordinates = NULL;
 
-       ret = maps_coordinates_create(1.0, 1.0, &coordinate_tmp);
+       ret = maps_coordinates_create(1.0, 1.0, &coordinates);
        assert_eq(ret, MAPS_ERROR_NONE);
 
-       ret = maps_view_object_overlay_set_coordinates(NULL, coordinate_tmp);
+       ret = maps_view_object_overlay_set_coordinates(NULL, coordinates);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
        ret = maps_view_object_overlay_set_coordinates(overlay, NULL);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_coordinates_destroy(coordinate_tmp);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_destroy(overlay);
+       ret = maps_coordinates_destroy(coordinates);
        assert_eq(ret, MAPS_ERROR_NONE);
 
        return 0;
@@ -1619,7 +1602,13 @@ int utc_maps_view_object_overlay_set_coordinates_n(void)
  */
 int utc_maps_view_object_overlay_get_coordinates_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       maps_coordinates_h coordinates = NULL;
+
+       ret = maps_view_object_overlay_get_coordinates(overlay, &coordinates);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
+       ret = maps_coordinates_destroy(coordinates);
+       assert_eq(ret, MAPS_ERROR_NONE);
        return 0;
 }
 
@@ -1630,26 +1619,14 @@ int utc_maps_view_object_overlay_get_coordinates_p(void)
  */
 int utc_maps_view_object_overlay_get_coordinates_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
+       maps_coordinates_h coordinates = NULL;
 
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_overlay_get_coordinates(NULL, &coordinate);
+       ret = maps_view_object_overlay_get_coordinates(NULL, &coordinates);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
        ret = maps_view_object_overlay_get_coordinates(overlay, NULL);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }
 
@@ -1660,7 +1637,9 @@ int utc_maps_view_object_overlay_get_coordinates_n(void)
  */
 int utc_maps_view_object_overlay_set_min_zoom_level_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       ret = maps_view_object_overlay_set_min_zoom_level(overlay, 1);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
        return 0;
 }
 
@@ -1671,26 +1650,12 @@ int utc_maps_view_object_overlay_set_min_zoom_level_p(void)
  */
 int utc_maps_view_object_overlay_set_min_zoom_level_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        ret = maps_view_object_overlay_set_min_zoom_level(NULL, 1);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
        ret = maps_view_object_overlay_set_min_zoom_level(overlay, -1);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }
 
@@ -1701,7 +1666,11 @@ int utc_maps_view_object_overlay_set_min_zoom_level_n(void)
  */
 int utc_maps_view_object_overlay_get_min_zoom_level_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       int zoom_level = 0;
+
+       ret = maps_view_object_overlay_get_min_zoom_level(overlay, &zoom_level);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
        return 0;
 }
 
@@ -1712,17 +1681,6 @@ int utc_maps_view_object_overlay_get_min_zoom_level_p(void)
  */
 int utc_maps_view_object_overlay_get_min_zoom_level_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        int zoom_level = 0;
 
        ret = maps_view_object_overlay_get_min_zoom_level(NULL, &zoom_level);
@@ -1731,9 +1689,6 @@ int utc_maps_view_object_overlay_get_min_zoom_level_n(void)
        ret = maps_view_object_overlay_get_min_zoom_level(overlay, NULL);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }
 
@@ -1744,7 +1699,9 @@ int utc_maps_view_object_overlay_get_min_zoom_level_n(void)
  */
 int utc_maps_view_object_overlay_set_max_zoom_level_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       ret = maps_view_object_overlay_set_max_zoom_level(overlay, 20);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
        return 0;
 }
 
@@ -1755,26 +1712,12 @@ int utc_maps_view_object_overlay_set_max_zoom_level_p(void)
  */
 int utc_maps_view_object_overlay_set_max_zoom_level_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        ret = maps_view_object_overlay_set_max_zoom_level(NULL, 5);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
        ret = maps_view_object_overlay_set_max_zoom_level(overlay, -1);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }
 
@@ -1785,7 +1728,11 @@ int utc_maps_view_object_overlay_set_max_zoom_level_n(void)
  */
 int utc_maps_view_object_overlay_get_max_zoom_level_p(void)
 {
-       /* tested in utc_maps_view_object_create_overlay_p */
+       int zoom_level = 0;
+
+       ret = maps_view_object_overlay_get_max_zoom_level(overlay, &zoom_level);
+       assert_eq(ret, MAPS_ERROR_NONE);
+
        return 0;
 }
 
@@ -1796,17 +1743,6 @@ int utc_maps_view_object_overlay_get_max_zoom_level_p(void)
  */
 int utc_maps_view_object_overlay_get_max_zoom_level_n(void)
 {
-       maps_coordinates_h coordinate = NULL;
-       Evas_Object *object = elm_button_add(win);
-       maps_view_overlay_type_e type = MAPS_VIEW_OVERLAY_NORMAL;
-       maps_view_object_h overlay = NULL;
-
-       ret = maps_coordinates_create(0.0, 0.0, &coordinate);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
-       ret = maps_view_object_create_overlay(coordinate, object, type, &overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        int zoom_level = 0;
 
        ret = maps_view_object_overlay_get_max_zoom_level(NULL, &zoom_level);
@@ -1815,9 +1751,6 @@ int utc_maps_view_object_overlay_get_max_zoom_level_n(void)
        ret = maps_view_object_overlay_get_max_zoom_level(overlay, NULL);
        assert_eq(ret, MAPS_ERROR_INVALID_PARAMETER);
 
-       ret = maps_view_object_destroy(overlay);
-       assert_eq(ret, MAPS_ERROR_NONE);
-
        return 0;
 }