[wearable][capability][TSIX-6577, fix issues because SPEC updated] 88/244788/1
authorwei625.zhang <wei625.zhang@samsung.com>
Thu, 24 Sep 2020 07:29:06 +0000 (15:29 +0800)
committerwei625.zhang <wei625.zhang@samsung.com>
Thu, 24 Sep 2020 07:32:54 +0000 (15:32 +0800)
Change-Id: I5c7d642c2d7496c1ab31ee301a87a8a3328581ae
Signed-off-by: wei625.zhang <wei625.zhang@samsung.com>
wearable/tct-capability-tests/capability/unsupported_sensor_wristup.html

index b21b9c5c6fdc8968397ccc6831569a1b9df839cc..3be6ea2c582eb0ca10fa59b2e54290e5b313ba33 100755 (executable)
@@ -32,21 +32,26 @@ Authors:
     <div id="log"></div>
     <script>
     //==== PRIORITY P1
-        test(function () {
-            if (tizen.systeminfo.getCapability("http://tizen.org/feature/profile") != "TV"){
-                if(tizen.sensorservice === undefined){
-                    assert_false(false, "unsupported sensor");
-                } else{
-                    if (is_caps_supported_by_system_info("http://tizen.org/feature/sensor.wrist_up") === false) {
-                        assert_throws({
-                            name: "NotSupportedError"
-                        }, function () {
-                            tizen.humanactivitymonitor.start("WRIST_UP");
-                        });
-                    }
-                }
+var t = async_test(document.title), GestureRecognitionCallback;
+
+t.step(function () {
+    GestureRecognitionCallback = t.step_func(function () {
+    });
+    if (tizen.systeminfo.getCapability("http://tizen.org/feature/profile") != "TV"){
+        if(tizen.sensorservice === undefined){
+            assert_false(false, "unsupported sensor");
+        } else{
+            if (is_caps_supported_by_system_info("http://tizen.org/feature/sensor.wrist_up") === false) {
+                assert_throws({
+                    name: "NotSupportedError"
+                }, function () {
+                    tizen.humanactivitymonitor.addGestureRecognitionListener("GESTURE_WRIST_UP", GestureRecognitionCallback);
+                });
             }
-        });
+        }
+    }
+    t.done();
+});
     </script>
   </body>
 </html>