[all][systeminfo][DPTTIZEN-3189, replace of deprecated method getCapabilities] 10/230810/2
authorqunfang.lin <qunfang.lin@samsung.com>
Wed, 15 Apr 2020 01:37:24 +0000 (09:37 +0800)
committerQunfang Lin <qunfang.lin@samsung.com>
Tue, 14 Apr 2020 08:42:11 +0000 (08:42 +0000)
add: 0, modify: 1, delete: 7

Change-Id: I6800a9c86a6a7c193bac810bd6cb568147dea841
Signed-off-by: qunfang.lin <qunfang.lin@samsung.com>
webWidgetTCT_device/test/tct/tests/TestSysteminfo.js

index 244cf2ebf2809dff318798f41fe4c1a4100907b3..cbc29aaeb9747e3920dff7d0706a2190c4551f3f 100755 (executable)
@@ -111,7 +111,6 @@ function SystemInfo_SystemInfoObject_systeminfo_attribute() {
 test(function () {
     assert_equals(typeof (tizen), "object", "Checking tizen object");
     assert_true(typeof (tizen.systeminfo) === "object", "Checking Systeminfo object");
-    assert_equals(typeof (tizen.systeminfo.getCapabilities), "function", "Checking type of getCapabilities");
     assert_equals(typeof (tizen.systeminfo.getPropertyValue), "function", "Checking type of getPropertyValue");
     assert_equals(typeof (tizen.systeminfo.addPropertyValueChangeListener), "function", "Checking type of addPropertyValueChangeListener");
     assert_equals(typeof (tizen.systeminfo.removePropertyValueChangeListener), "function", "Checking type of removePropertyValueChangeListener");
@@ -161,20 +160,6 @@ test(function () {
 
 }
 
-function SystemInfoDeviceCapability_notexist() {
-//==== TEST: SystemInfoDeviceCapability_notexist
-//==== PRIORITY P3
-//==== LABEL Check if interface SystemInfoDeviceCapability exists, it should not.
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfoDeviceCapability:SystemInfoDeviceCapability U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA NIO
-
-test(function () {
-    check_no_interface_object("SystemInfoDeviceCapability");
-}, 'SystemInfoDeviceCapability_notexist');
-
-}
-
 function SystemInfoDeviceOrientation_notexist() {
 //==== TEST: SystemInfoDeviceOrientation_notexist
 //==== PRIORITY P3
@@ -316,21 +301,6 @@ test(function () {
 
 }
 
-function SystemInfoDeviceCapability_extend() {
-//==== TEST: SystemInfoDeviceCapability_extend
-//==== PRIORITY P3
-//==== LABEL Check if instance of interface SystemInfoDeviceCapability can be extended with new property
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfoDeviceCapability:SystemInfoDeviceCapability U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA OBX
-var deviceCapabilities = tizen.systeminfo.getCapabilities();
-
-test(function () {
-    check_extensibility(deviceCapabilities);
-}, 'SystemInfoDeviceCapability_extend');
-
-}
-
 function SystemInfo_getCapability_network_nfc() {
 //==== TEST: SystemInfo_getCapability_network_nfc
 //==== LABEL Check if attribute nfc of SystemInfoDeviceCapability exists, has type Boolean and is readonly
@@ -879,50 +849,6 @@ test(function () {
 
 }
 
-function SystemInfo_getCapabilities_exist() {
-//==== TEST: SystemInfo_getCapabilities_exist
-//==== LABEL Check if method getCapabilities of SystemInfo exists
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfo:getCapabilities M
-//==== TEST_CRITERIA ME
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-test(function () {
-    assert_true("getCapabilities" in tizen.systeminfo, "No getCapabilities method in tizen.systeminfo.");
-    check_method_exists(tizen.systeminfo, "getCapabilities");
-}, 'SystemInfo_getCapabilities_exist');
-
-}
-
-function SystemInfo_getCapabilities() {
-//==== TEST: SystemInfo_getCapabilities
-//==== LABEL Check method getCapabilities of SystemInfo
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfo:getCapabilities M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA MNA MR
-
-test(function () {
-    var deviceCapabilities = tizen.systeminfo.getCapabilities(), i;
-    for(i = 0; i < SystemInfoDeviceCapability.length; i++) {
-        assert_true(SystemInfoDeviceCapability[i] in deviceCapabilities,
-            "There is no "+SystemInfoDeviceCapability[i]+
-            " attribute in tizen.systeminfo.getCapabilities().");
-    }
-}, 'SystemInfo_getCapabilities');
-
-}
-
-function SystemInfo_getCapabilities_extra_argument() {
-//==== TEST: SystemInfo_getCapabilities_extra_argument
-//==== LABEL Check if method getCapabilities of SystemInfo accepts extra argument
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfo:getCapabilities M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA MNAEX
-
-test(function () {
-    checkExtraArgument(tizen.systeminfo, "getCapabilities");
-}, 'SystemInfo_getCapabilities_extra_argument');
-
-}
-
 function SystemInfoDisplay_brightness_attribute() {
 //==== TEST: SystemInfoDisplay_brightness_attribute
 //==== LABEL Check if attribute brightness of SystemInfoDisplay exists, has type Number and is readonly
@@ -2093,23 +2019,6 @@ test(function () {
 
 }
 
-function SystemInfoDeviceCapability_autoRotation_attribute() {
-//==== TEST: SystemInfoDeviceCapability_autoRotation_attribute
-//==== LABEL Check attribute autoRotation of SystemInfoDeviceCapability
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfoDeviceCapability:autoRotation A
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA AE AT ARO
-var deviceCapabilities = tizen.systeminfo.getCapabilities();
-
-test(function () {
-    assert_own_property(deviceCapabilities, "autoRotation",
-        "SystemInfoDeviceCapability does not own autoRotation property.");
-    check_readonly(deviceCapabilities, "autoRotation",
-        deviceCapabilities.autoRotation, "boolean", null);
-}, 'SystemInfoDeviceCapability_autoRotation_attribute');
-
-}
-
 function SystemInfo_getCapability_sensor_barometer_wakeup() {
 //==== TEST: SystemInfo_getCapability_sensor_barometer_wakeup
 //==== LABEL Check attribute barometerWakeup of SystemInfoDeviceCapability
@@ -2348,27 +2257,6 @@ test(function () {
 
 }
 
-function SystemInfoDeviceCapability_telephonySms_attribute() {
-//==== TEST: SystemInfoDeviceCapability_telephonySms_attribute
-//==== LABEL Check attribute telephonySms of SystemInfoDeviceCapability
-//==== SPEC Tizen Web API:System:SystemInfo:SystemInfoDeviceCapability:telephonySms A
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/systeminfo.html
-//==== TEST_CRITERIA AE AT ARO
-
-var deviceCapabilities = tizen.systeminfo.getCapabilities();
-test(function () {
-
-
-    assert_own_property(deviceCapabilities, "telephonySms", "SystemInfoDeviceCapability does not own telephonySms property.");
-
-
-    check_readonly(deviceCapabilities, "telephonySms", deviceCapabilities.telephonySms, "boolean", null);
-
-
-}, 'SystemInfoDeviceCapability_telephonySms_attribute');
-
-}
-
 function SystemInfo_getCapability_network_telephony() {
 //==== TEST: SystemInfo_getCapability_network_telephony
 //==== LABEL Check attribute telephony of SystemInfoDeviceCapability