[UTC][tzsh-quickpanel][Non-ACR][Don't assert if there're no quickpanel service] 19/230519/1
authorJunseok, Kim <juns.kim@samsung.com>
Fri, 10 Apr 2020 07:49:35 +0000 (16:49 +0900)
committerJunSeok Kim <juns.kim@samsung.com>
Fri, 10 Apr 2020 07:50:21 +0000 (07:50 +0000)
Change-Id: Icbaafcfb1cf22b674d83aee4f774f63ca9f6812f

src/utc/tzsh-quickpanel/utc-tzsh-quickpanel.c

index c577cc450e9356473e76a1d0d01880f8dcd92788..506874adec2fac8da869bb4deb7d34dbecdf6286 100755 (executable)
@@ -640,13 +640,22 @@ int utc_tzsh_quickpanel_scrollable_state_set_p1(void)
     assert_neq(qp, NULL);
 
     ret = tzsh_quickpanel_scrollable_state_set(qp, TZSH_QUICKPANEL_STATE_SCROLLABLE_SET);
-    assert_eq(ret, TZSH_ERROR_NONE);
+    if (ret != TZSH_ERROR_NO_SERVICE)
+        assert_eq(ret, TZSH_ERROR_NONE);
+    else
+        assert_eq(ret, TZSH_ERROR_NO_SERVICE);
 
     ret = tzsh_quickpanel_scrollable_state_set(qp, TZSH_QUICKPANEL_STATE_SCROLLABLE_UNSET);
-    assert_eq(ret, TZSH_ERROR_NONE);
+    if (ret != TZSH_ERROR_NO_SERVICE)
+        assert_eq(ret, TZSH_ERROR_NONE);
+    else
+        assert_eq(ret, TZSH_ERROR_NO_SERVICE);
 
     ret = tzsh_quickpanel_scrollable_state_set(qp, TZSH_QUICKPANEL_STATE_SCROLLABLE_RETAIN);
-    assert_eq(ret, TZSH_ERROR_NONE);
+    if (ret != TZSH_ERROR_NO_SERVICE)
+        assert_eq(ret, TZSH_ERROR_NONE);
+    else
+        assert_eq(ret, TZSH_ERROR_NO_SERVICE);
 
     // cleanup resource
     tzsh_quickpanel_destroy(qp);
@@ -695,7 +704,10 @@ int utc_tzsh_quickpanel_scrollable_state_get_p1(void)
     assert_neq(qp, NULL);
 
     ret = tzsh_quickpanel_scrollable_state_set(qp, TZSH_QUICKPANEL_STATE_SCROLLABLE_SET);
-    assert_eq(ret, TZSH_ERROR_NONE);
+    if (ret != TZSH_ERROR_NO_SERVICE)
+        assert_eq(ret, TZSH_ERROR_NONE);
+    else
+        assert_eq(ret, TZSH_ERROR_NO_SERVICE);
 
     ret = tzsh_quickpanel_scrollable_state_get(qp, &scrollable);
     if (ret != TZSH_ERROR_NO_SERVICE)
@@ -738,7 +750,10 @@ int utc_tzsh_quickpanel_scrollable_state_get_p2(void)
     assert_neq(qp, NULL);
 
     ret = tzsh_quickpanel_scrollable_state_set(qp, TZSH_QUICKPANEL_STATE_SCROLLABLE_UNSET);
-    assert_eq(ret, TZSH_ERROR_NONE);
+    if (ret != TZSH_ERROR_NO_SERVICE)
+        assert_eq(ret, TZSH_ERROR_NONE);
+    else
+        assert_eq(ret, TZSH_ERROR_NO_SERVICE);
 
     ret = tzsh_quickpanel_scrollable_state_get(qp, &state);
     if (ret != TZSH_ERROR_NO_SERVICE)