[Power] review
authorWitold Choinkowski <w.choinkowsk@samsung.com>
Fri, 4 Oct 2013 14:11:50 +0000 (16:11 +0200)
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>
Tue, 8 Oct 2013 07:04:39 +0000 (07:04 +0000)
Change-Id: Idbdceb4eab3b56e425d5b57fc689d659d3436e9c

58 files changed:
tct-power-tizen-tests/power/PowerManagerObject_notexist.html
tct-power-tizen-tests/power/PowerManager_extend.html
tct-power-tizen-tests/power/PowerManager_getScreenBrightness.html
tct-power-tizen-tests/power/PowerManager_getScreenBrightness_check_change.html [changed mode: 0755->0644]
tct-power-tizen-tests/power/PowerManager_getScreenBrightness_exist.html
tct-power-tizen-tests/power/PowerManager_getScreenBrightness_extra_argument.html
tct-power-tizen-tests/power/PowerManager_in_tizen.html
tct-power-tizen-tests/power/PowerManager_isScreenOn.html
tct-power-tizen-tests/power/PowerManager_isScreenOn_check_change.html
tct-power-tizen-tests/power/PowerManager_isScreenOn_exist.html
tct-power-tizen-tests/power/PowerManager_isScreenOn_extra_argument.html
tct-power-tizen-tests/power/PowerManager_notexist.html
tct-power-tizen-tests/power/PowerManager_release.html
tct-power-tizen-tests/power/PowerManager_release_correct_check.html
tct-power-tizen-tests/power/PowerManager_release_exist.html
tct-power-tizen-tests/power/PowerManager_release_missarg.html
tct-power-tizen-tests/power/PowerManager_release_resource_TypeMismatch.html
tct-power-tizen-tests/power/PowerManager_request.html
tct-power-tizen-tests/power/PowerManager_request_CPU_AWAKE.html
tct-power-tizen-tests/power/PowerManager_request_SCREEN_DIM.html
tct-power-tizen-tests/power/PowerManager_request_SCREEN_NORMAL.html
tct-power-tizen-tests/power/PowerManager_request_exist.html
tct-power-tizen-tests/power/PowerManager_request_missarg.html
tct-power-tizen-tests/power/PowerManager_request_resource_TypeMismatch.html
tct-power-tizen-tests/power/PowerManager_request_state_TypeMismatch.html
tct-power-tizen-tests/power/PowerManager_restoreScreenBrightness.html
tct-power-tizen-tests/power/PowerManager_restoreScreenBrightness_check_effect.html [changed mode: 0755->0644]
tct-power-tizen-tests/power/PowerManager_restoreScreenBrightness_exist.html
tct-power-tizen-tests/power/PowerManager_restoreScreenBrightness_extra_argument.html
tct-power-tizen-tests/power/PowerManager_setScreenBrightness.html [changed mode: 0755->0644]
tct-power-tizen-tests/power/PowerManager_setScreenBrightness_brightness_TypeMismatch.html
tct-power-tizen-tests/power/PowerManager_setScreenBrightness_brightness_invalid_val.html
tct-power-tizen-tests/power/PowerManager_setScreenBrightness_exist.html
tct-power-tizen-tests/power/PowerManager_setScreenBrightness_missarg.html
tct-power-tizen-tests/power/PowerManager_setScreenStateChangeListener.html
tct-power-tizen-tests/power/PowerManager_setScreenStateChangeListener_exist.html
tct-power-tizen-tests/power/PowerManager_setScreenStateChangeListener_listener_TypeMismatch.html
tct-power-tizen-tests/power/PowerManager_setScreenStateChangeListener_listener_invalid_cb.html
tct-power-tizen-tests/power/PowerManager_setScreenStateChangeListener_missarg.html
tct-power-tizen-tests/power/PowerManager_turnScreenOff.html
tct-power-tizen-tests/power/PowerManager_turnScreenOff_exist.html
tct-power-tizen-tests/power/PowerManager_turnScreenOff_extra_argument.html
tct-power-tizen-tests/power/PowerManager_turnScreenOff_successful.html
tct-power-tizen-tests/power/PowerManager_turnScreenOn.html
tct-power-tizen-tests/power/PowerManager_turnScreenOn_exist.html
tct-power-tizen-tests/power/PowerManager_turnScreenOn_extra_argument.html
tct-power-tizen-tests/power/PowerManager_turnScreenOn_method_exists.html
tct-power-tizen-tests/power/PowerManager_turnScreenOn_successful.html
tct-power-tizen-tests/power/PowerManager_unsetScreenStateChangeListener.html
tct-power-tizen-tests/power/PowerManager_unsetScreenStateChangeListener_exist.html
tct-power-tizen-tests/power/PowerManager_unsetScreenStateChangeListener_extra_argument.html
tct-power-tizen-tests/power/PowerManager_unsetScreenStateChangeListener_successful.html
tct-power-tizen-tests/power/ScreenStateChangeCallback_notexist.html
tct-power-tizen-tests/power/ScreenStateChangeCallback_onchanged.html
tct-power-tizen-tests/power/support/unitcommon.js [new file with mode: 0644]
tct-power-tizen-tests/resources/unitcommon.js [deleted file]
tct-power-tizen-tests/tests.full.xml [changed mode: 0755->0644]
tct-power-tizen-tests/tests.xml [changed mode: 0755->0644]

index b0dceba5ff635626dd0ccbfada280c0b67ed3180..c376c56ef60c44350edad2fbd38f152de75eacf6 100644 (file)
@@ -16,14 +16,14 @@ limitations under the License.
 
 
 Authors:
-    Jakub Siewierski <j.siewierski@samsung.com>
+        Jakub Siewierski <j.siewierski@samsung.com>
 
 -->
-<html lang="en">
+<html>
 <head>
 <title>PowerManagerObject_notexist</title>
 <meta charset="utf-8"/>
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,11 +33,11 @@ Authors:
 //==== LABEL Check if interface PowerManagerObject exists, it should not.
 //==== PRIORITY P3
 //==== SPEC Tizen Web API:System:Power:PowerManagerObject:PowerManagerObject U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA NIO
 test(function () {
     check_no_interface_object("PowerManagerObject");
-}, "PowerManagerObject_notexist");
+}, document.title);
 
 </script>
 </body>
index 465548b4e677676d0c687b9fc23f56db9110278c..31298d0bc6142f3b02a9d48d2a5d8f93db258148 100644 (file)
@@ -17,14 +17,14 @@ limitations under the License.
 
 
 Authors:
-    Marcin Kaminski <marcin.ka@samsung.com>
+        Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
 <html>
 
 <head>
 <title>PowerManager_extend</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -35,11 +35,11 @@ Authors:
 //==== LABEL Check if tizen.power can have new properties added, it should not.
 //==== PRIORITY P3
 //==== SPEC Tizen Web API:System:Power:PowerManager:PowerManager U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA OBX
 test(function () {
     check_extensibility(tizen.power);
-}, "PowerManager_extend");
+}, document.title);
 
 </script>
 </body>
index 2f0a491300c097e2f4f246f70420d77772f882d4..5cbfd66e5a9f84b698018a2ce24c5ab6a87740a2 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_getScreenBrightness</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,13 +31,14 @@ Authors:
 //==== TEST: PowerManager_getScreenBrightness
 //==== LABEL Check if getScreenBrightness method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:getScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
 test(function () {
     var retVal = tizen.power.getScreenBrightness();
-    assert_type(retVal, "number");
+    assert_type(retVal, "number", "Method getScreenBrightness returns wrong type");
     assert_true(retVal <= 1 && retVal >= 0, "brigthness should be in range from 0 to 1, but was: " + retVal);
-}, "PowerManager_getScreenBrightness");
+}, document.title);
+
 </script>
 </body>
 </html>
old mode 100755 (executable)
new mode 100644 (file)
index 07cf279..81da777
@@ -18,15 +18,15 @@ limitations under the License.
 
 
 Authors:
-    Krzysztof Lachacz <k.lachacz@samsung.com>
+        Krzysztof Lachacz <k.lachacz@samsung.com>
 -->
 
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_getScreenBrightness_check_change</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,9 +35,9 @@ Authors:
 <script type="text/javascript">
 
 //==== TEST: PowerManager_getScreenBrightness_check_change
-//==== LABEL check whether getScreenBrightness() method gets the screen brightness level correctly
+//==== LABEL Check whether getScreenBrightness() method gets the screen brightness level correctly
 //==== SPEC Tizen Web API:System:Power:PowerManager:getScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== PRIORITY P1
 //==== TEST_CRITERIA MNA
 var initialValue, defaultValue, currentValue;
@@ -65,11 +65,8 @@ test(function () {
 
     currentValue = tizen.power.getScreenBrightness();
     assert_not_equals(currentValue, defaultValue, "screen brightness was not changed");
-}, "PowerManager_getScreenBrightness_check_change");
+}, document.title);
 
 </script>
-
 </body>
-
 </html>
-
index efc91b749e64dcb5c78d521057609de8816c20a7..82896fcbbf6c5f2b73482e33f7b40e0cdbe4a525 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_getScreenBrightness_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_getScreenBrightness_exist
 //==== LABEL Check if getScreenBrightness method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:getScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("getScreenBrightness" in tizen.power, "getScreenBrightness method sould be implemented");
     check_method_exists(tizen.power, "getScreenBrightness");
-}, "PowerManager_getScreenBrightness_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index 3607b8f5b962c102c82aa2d37e07dc836d59e4b1..6850041dc5159a06fb36d84e427e3ff5c484b219 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_getScreenBrightness_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:getScreenBrightness M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "getScreenBrightness");
-}, "PowerManager_getScreenBrightness_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
index 2ac0eec6a6f576005a64e23d13a3545e01189661..8118ab8056bd8f247959ba930f015a4aba9065bc 100644 (file)
@@ -16,14 +16,14 @@ limitations under the License.
 
 
 Authors:
-    Piotr Szydelko <p.szydelko@samsung.com>
+        Piotr Szydelko <p.szydelko@samsung.com>
 
 -->
-<html lang="en">
+<html>
 <head>
 <title>PowerManager_in_tizen</title>
 <meta charset="utf-8"/>
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,12 +33,12 @@ Authors:
 //==== LABEL Check if Tizen implements interface PowerManagerObject and has attribute power
 //==== PRIORITY P3
 //==== SPEC Tizen Web API:System:Power:PowerManager:PowerManager U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA OBME
 test(function () {
     assert_own_property(tizen, "power", "Tizen should implement PowerManagerObject");
     assert_equals(typeof(tizen.power), "object", "tizen.power should be object");
-}, "PowerManager_in_tizen");
+}, document.title);
 
 </script>
 </body>
index dfeb17c7e9e2cf03654a7065e1a0d50de748f1e7..e14a1326cb7948258a99f7ddadff813c62702af9 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_isScreenOn</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_isScreenOn
 //==== LABEL Check if isScreenOn method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:isScreenOn M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
-test(function() {
+test(function () {
     var retVal = tizen.power.isScreenOn();
-    assert_type(retVal, "boolean");
-}, "PowerManager_isScreenOn");
+    assert_type(retVal, "boolean", "Method isScreenOn returns wrong type");
+}, document.title);
+
 </script>
 </body>
 </html>
index 6e7e0a0ab28788d1aaf66169399b81b03eb55ac2..bcdee4299a3cd7e51e7b24f8da49325d9478a9bc 100644 (file)
@@ -18,15 +18,15 @@ limitations under the License.
 
 
 Authors:
-    Krzysztof Lachacz <k.lachacz@samsung.com>
+        Krzysztof Lachacz <k.lachacz@samsung.com>
 -->
 
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_isScreenOn_check_change</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,9 +35,9 @@ Authors:
 <script type="text/javascript">
 
 //==== TEST: PowerManager_isScreenOn_check_change
-//==== LABEL check whether isScreenOn() method gets the screen state correctly
+//==== LABEL Check whether isScreenOn() method gets the screen state correctly
 //==== SPEC Tizen Web API:System:Power:PowerManager:isScreenOn M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== PRIORITY P1
 //==== TEST_CRITERIA MNA MR
 test(function () {
@@ -52,11 +52,8 @@ test(function () {
     isScreenOn = tizen.power.isScreenOn();
     assert_type(isScreenOn, "boolean", "isScreenOn() return type check");
     assert_false(isScreenOn, "Check if screen is off");
-}, "PowerManager_isScreenOn_check_change");
+}, document.title);
 
 </script>
-
 </body>
-
 </html>
-
index 72ff0bbc4e41ef5a20b3b82c7d2c94e94f62e9e9..d276e3ca5a42f5634742166777cfaddbf016b9f2 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_isScreenOn_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_isScreenOn_exist
 //==== LABEL Check if isScreenOn method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:isScreenOn M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("isScreenOn" in tizen.power, "isScreenOn method sould be implemented");
     check_method_exists(tizen.power, "isScreenOn");
-}, "PowerManager_isScreenOn_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index c02dd77b65c5b639f258cf2e1e5de0968117e1dd..373d16226e0e5e504d3d191f1879c988cc287718 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_isScreenOn_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:isScreenOn M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "isScreenOn");
-}, "PowerManager_isScreenOn_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
index 93851df46f702d93f9dba4882bd44263b5147455..9733db08236c1f67a304971c28cc4bd8b2ce1bb7 100644 (file)
@@ -16,14 +16,14 @@ limitations under the License.
 
 
 Authors:
-    Jakub Siewierski <j.siewierski@samsung.com>
+        Jakub Siewierski <j.siewierski@samsung.com>
 
 -->
-<html lang="en">
+<html>
 <head>
 <title>PowerManager_notexist</title>
 <meta charset="utf-8"/>
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,11 +33,11 @@ Authors:
 //==== LABEL Check if interface PowerManager exists, it should not.
 //==== PRIORITY P3
 //==== SPEC Tizen Web API:System:Power:PowerManager:PowerManager U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA NIO
 test(function () {
     check_no_interface_object("PowerManager");
-}, "PowerManager_notexist");
+}, document.title);
 
 </script>
 </body>
index 1f5d562fde9650ae11e33b8e12c9f862aed08d1f..b9f96db8fb832cf08c010f4ed9dd248d87fc6372 100644 (file)
@@ -21,12 +21,12 @@ Authors:
         Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
-<html lang="en">
+<html>
 
 <head>
-<title>Messaging/UTC_power</title>
+<title>PowerManager_release</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -36,7 +36,7 @@ Authors:
 //==== TEST: PowerManager_release
 //==== LABEL Check if release() method called with proper argument does not throw exceptions
 //==== SPEC Tizen Web API:System:Power:PowerManager:release M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#releaseid2576878
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA MR
 var ret1Value = null, ret2Value = null;
 
@@ -46,8 +46,8 @@ test(function () {
 
         assert_equals(ret1Value, undefined, "release returns wrong value");
         assert_equals(ret2Value, undefined, "release returns wrong value");
-    }, "PowerManager_release");
+    }, document.title);
+
 </script>
 </body>
 </html>
-
index cfbac65a6d0b66ee5648d8275942fb2312f30a44..a516e5aa64a4ccee94625d076894434af75fc19f 100644 (file)
@@ -36,7 +36,7 @@ Authors:
 <title>PowerManager_release_correct_check</title>
 <meta name="flags" content="" />
 <meta name="assert" content="Check if PowerManager's release method works" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 <body>
 <div id="log"></div>
@@ -48,19 +48,17 @@ Authors:
 //==== EXPECT Pass
 //==== PRE Please set backlight time to 15 seconds
 //==== SPEC Tizen Web API:System:Power:PowerManager:release M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#releaseid2576878
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA MAST
 setup({timeout: 90000});
-var t = async_test("PowerManager_release_correct_check", {timeout:90000});
-
-function onScreenStateChanged(previousState, changedState) {
-    t.step(function() {
+var t = async_test(document.title, {timeout: 90000});
+t.step(function () {
+    function onScreenStateChanged(previousState, changedState) {
         assert_not_equals(previousState, changedState, "Screen state should be changed.");
-    });
-    t.done();
-}
+        
+        t.done();
+    }
 
-try {
     tizen.power.release("SCREEN");
     tizen.power.release("CPU");
 
@@ -70,15 +68,11 @@ try {
     tizen.power.release("SCREEN");
     setTimeout(function () {
         t.step(function () {
-            assert_unreached("tizen.power.release failure," +
+            assert_unreached("tizen.power.release failure, " +
                     "screen state change has not been detected!");
         });
     }, 20000);
-} catch (e) {
-    t.step(function() {
-        assert_unreached("tizen.power.setScreenStateChangeListener exception: " + e.message);
-    });
-}
+});
 </script>
 </body>
 </html>
index ba52a95cb876957d429e5b7e23c12b2b71987870..83902ccc9543c785178343ef70e98cddbe0f3c47 100644 (file)
@@ -36,7 +36,7 @@ Authors:
 <title>PowerManager_release_exist</title>
 <meta name="flags" content="" />
 <meta name="assert" content="Check if release method exists" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 <body>
 <div id="log"></div>
@@ -44,12 +44,12 @@ Authors:
 //==== TEST: PowerManager_release_exist
 //==== LABEL Check if method release of PowerManager exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:release M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
-test(function() {
+test(function () {
     assert_true("request" in tizen.power, "No release method in tizen.power.");
     check_method_exists(tizen.power, "request");
-}, "PowerManager_release_exist");
+}, document.title);
 
 </script>
 </body>
index a1145168c61b870b78e45a713b77e910145a1a83..e606fdb4549be0ed4df91ef96c54043926b28ebf 100644 (file)
@@ -20,12 +20,12 @@ Authors:
         Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_release_missarg</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,19 +35,14 @@ Authors:
 //==== TEST: PowerManager_release_missarg
 //==== LABEL Check if release() method called without all obligatory arguments throws an exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:release M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMA
 test(function () {
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.release();
     });
-}, "PowerManager_release_missarg");
+}, document.title);
 
 </script>
-
 </body>
-
 </html>
-
index a9a6a544b6994cad71b1f052564e29c0bf51d2fc..57720e40724cbe877273fbfbc7e0d1eaab459557 100644 (file)
@@ -36,7 +36,7 @@ Authors:
 <title>PowerManager_release_resource_TypeMismatch</title>
 <meta name="flags" content="" />
 <meta name="assert" content="Check if tizen.power.release throws TYPE_MISMATCH_ERR" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 <body>
 <div id="log"></div>
@@ -45,25 +45,26 @@ Authors:
 //==== LABEL Check if release() method throws TypeMismatchException when incorrect resource given
 //==== PRIORITY: P2
 //==== SPEC Tizen Web API:System:Power:PowerManager:release M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MC
-test(function() {
-    assert_throws("TYPE_MISMATCH_ERR", function() {
+test(function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.release(true);
     });
 
-    assert_throws("TYPE_MISMATCH_ERR", function() {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.release(1);
     });
 
-    assert_throws("TYPE_MISMATCH_ERR", function() {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.release(null);
     });
 
-    assert_throws("TYPE_MISMATCH_ERR", function() {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.release(undefined);
     });
-}, "PowerManager_release_resource_TypeMismatch");
+}, document.title);
+
 </script>
 </body>
 </html>
index ccd26c695d6f19703e527929c3bb77f41f10b561..fc31ed71fb5e58e548f934466aa0847417217ee4 100644 (file)
@@ -36,7 +36,7 @@ Authors:
 <head>
 <title>PowerManager_request</title>
 <meta charset="utf-8"/>
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 <body>
 <div id="log"></div>
@@ -50,10 +50,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA MAST MR
-setup({timeout:90000});
-var t = async_test("PowerManager_request", {timeout:90000}), timeout, retValue = null;
+setup({timeout: 90000});
+var t = async_test(document.title, {timeout: 90000}), timeout, retValue = null;
 
-t.step(function() {
+t.step(function () {
     tizen.power.release("SCREEN");
     tizen.power.release("CPU");
 
index 3e5e396cd18d85ace1bb0c0bd2dd111401e6f40e..3b52c228f9d20fc87ceb5ace7d23bf47cdbcf087 100644 (file)
@@ -21,12 +21,12 @@ Authors:
 
 -->
 
-<html lang="en">
+<html>
 
 <head>
-<title>PowerManager_request_PowerManager_request_CPU_AWAKE</title>
+<title>PowerManager_request_CPU_AWAKE</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -35,13 +35,13 @@ Authors:
 //==== TEST: PowerManager_request_CPU_AWAKE
 //==== LABEL Check whether request() method with CPU resource and CPU_AWAKE state does not throw exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA
 test(function () {
         tizen.power.request("CPU", "CPU_AWAKE");
         tizen.power.release("CPU");
-    }, "PowerManager_request_CPU_AWAKE");
+    }, document.title);
+
 </script>
 </body>
 </html>
-
index 3359bb4e67efa14cdd1826417d93fedab62bd216..b041015f557674ad96f7806b7286514ea4d718f9 100644 (file)
@@ -21,12 +21,12 @@ Authors:
 
 -->
 
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_request_SCREEN_DIM</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -35,13 +35,13 @@ Authors:
 //==== TEST: PowerManager_request_SCREEN_DIM
 //==== LABEL Check whether request() method with SCREEN resource and SCREEN_DIM state does not throw exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA
 test(function () {
         tizen.power.request("SCREEN",  "SCREEN_DIM" );
         tizen.power.release("SCREEN");
-    }, "PowerManager_request_SCREEN_DIM");
+    }, document.title);
+
 </script>
 </body>
 </html>
-
index bdf2a3405332b679201b490564400fa0581e1bf5..4e8763d6d55386a29a3a4ae17ce44534232db815 100644 (file)
@@ -21,12 +21,12 @@ Authors:
 
 -->
 
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_request_SCREEN_NORMAL</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -35,13 +35,13 @@ Authors:
 //==== TEST: PowerManager_request_SCREEN_NORMAL
 //==== LABEL Check whether request() method with SCREEN resource and SCREEN_NORMAL state does not throw exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA
 test(function () {
         tizen.power.request("SCREEN", "SCREEN_NORMAL");
         tizen.power.release("SCREEN");
-    }, "PowerManager_request_SCREEN_NORMAL");
+    }, document.title);
+
 </script>
 </body>
 </html>
-
index 49bceaa24d2f802f51e49aa20f6cfad62f6ac00b..79717d22f75ac9f7373e7da1315b9f47d23dd7da 100644 (file)
@@ -16,7 +16,7 @@ limitations under the License.
 
 
 Authors:
-    Marcin Kaminski <marcin.ka@samsung.com>
+        Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
 
@@ -26,7 +26,7 @@ Authors:
 <link rel="help" href="https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html" />
 <meta name="flags" content="" />
 <meta name="assert" content="Check if request method exists" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 <body>
 <div id="log"></div>
@@ -34,12 +34,12 @@ Authors:
 //==== TEST: PowerManager_request_exist
 //==== LABEL Check if method request of PowerManager exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
-test(function() {
+test(function () {
     assert_true("request" in tizen.power, "No request method in tizen.power.");
     check_method_exists(tizen.power, "request");
-}, "PowerManager_request_exist");
+}, document.title);
 
 </script>
 </body>
index f936e0bd164b7f4ca24e8ff260cd7552ec2f4d61..85f30f3aef464b3c6aac13da1f459644e1e446df 100644 (file)
@@ -20,12 +20,12 @@ Authors:
         Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_request_missarg</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,29 +35,20 @@ Authors:
 //==== TEST: PowerManager_request_missarg
 //==== LABEL Check if request() method called without all obligatory arguments throws an exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMA
 test(function () {
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request();
     });
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("SCREEN");
     });
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("CPU");
     });
-}, "PowerManager_request_missarg");
+}, document.title);
 
 </script>
-
 </body>
-
 </html>
-
index 3a6b0c7f660d34652d0dc86858f57cdb477ec4aa..8357b2025148bbdd0cf6abd267868d1754e8b583 100644 (file)
@@ -36,7 +36,7 @@ Authors:
 <title>PowerManager_request_resource_TypeMismatch</title>
 <meta name="flags" content="" />
 <meta name="assert" content="Check if request throws TYPE_MISMATCH_ERR" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 <body>
@@ -46,55 +46,44 @@ Authors:
 //==== LABEL Check if request() method throws TypeMismatchException when incorrect resource given
 //==== PRIORITY: P2
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MC
 var i;
 
-test(function() {
-    assert_throws("TYPE_MISMATCH_ERR",function() {
+test(function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request(true, "SCREEN_NORMAL");
     });
 
     for (i = 0; i< PowerScreenStates.length; i++) {
-        assert_throws({
-            name: TYPE_MISMATCH_ERR
-        }, function () {
+        assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
             tizen.power.request(1, PowerScreenStates[i]);
         });
     }
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request(1, "CPU_AWAKE");
     });
 
     for (i = 0; i< PowerScreenStates.length; i++) {
-        assert_throws({
-            name: TYPE_MISMATCH_ERR
-        }, function () {
+        assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
             tizen.power.request(null, PowerScreenStates[i]);
         });
     }
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request(null, "CPU_AWAKE");
     });
 
     for (i = 0; i< PowerScreenStates.length; i++) {
-        assert_throws({
-            name: TYPE_MISMATCH_ERR
-        }, function () {
+        assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
             tizen.power.request(undefined, PowerScreenStates[i]);
         });
     }
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request(undefined, "CPU_AWAKE");
     });
 
-}, "PowerManager_request_resource_TypeMismatch");
+}, document.title);
+
 </script>
 </body>
 </html>
index f24672d805d83d8b386b73e9ac2b3b2c30f26162..b663373eeaf00799f64d5e26dce20dd01b168844 100644 (file)
@@ -35,7 +35,7 @@ Authors:
 <title>PowerManager_request_state_TypeMismatch</title>
 <meta name="flags" content="" />
 <meta name="assert" content="Check if request throws TYPE_MISMATCH_ERR" />
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 <body>
@@ -45,47 +45,36 @@ Authors:
 //==== LABEL Check if request() method throws TypeMismatchException when incorrect state given
 //==== PRIORITY: P2
 //==== SPEC Tizen Web API:System:Power:PowerManager:request M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MC
-test(function() {
-    assert_throws("TYPE_MISMATCH_ERR",function() {
+test(function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request(true, "SCREEN_NORMAL");
     });
 
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("SCREEN", 1);
     });
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("CPU", 1);
     });
 
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("SCREEN", null);
     });
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("CPU", null);
     });
 
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("SCREEN", undefined);
     });
-    assert_throws({
-        name: TYPE_MISMATCH_ERR
-    }, function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.request("CPU", undefined);
     });
 
-}, "PowerManager_request_state_TypeMismatch");
+}, document.title);
+
 </script>
 </body>
 </html>
index 0f3b1c44713524e0c8b127268d1272af1bf6d76a..72a14bc60d87063c9d6fbe392ef47583910d9e92 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_restoreScreenBrightness</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_restoreScreenBrightness
 //==== LABEL Check if restoreScreenBrightness method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:restoreScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
-test(function() {
+test(function () {
     var retVal = tizen.power.restoreScreenBrightness();
     assert_equals(retVal, undefined, "method should return nothing");
-}, "PowerManager_restoreScreenBrightness");
+}, document.title);
+
 </script>
 </body>
 </html>
old mode 100755 (executable)
new mode 100644 (file)
index 3ad79c2..3eabe1e
@@ -18,15 +18,15 @@ limitations under the License.
 
 
 Authors:
-    Krzysztof Lachacz <k.lachacz@samsung.com>
+        Krzysztof Lachacz <k.lachacz@samsung.com>
 -->
 
-<html lang="en">
+<html>
 
 <head>
 <title>PowerManager_restoreScreenBrightness_check_effect</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,9 +35,9 @@ Authors:
 <script type="text/javascript">
 
 //==== TEST: PowerManager_restoreScreenBrightness_check_effect
-//==== LABEL check if restoreScreenBrightness() method restores the screen brightness to the system default setting value
+//==== LABEL Check if restoreScreenBrightness() method restores the screen brightness to the system default setting value
 //==== SPEC Tizen Web API:System:Power:PowerManager:restoreScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== STEP Check if restoreScreenBrightness method called with non-optional arguments does what it should
 //==== EXPECT method does what it should to do
 //==== EXECUTION_TYPE manual
@@ -72,8 +72,9 @@ test(function () {
     tizen.power.restoreScreenBrightness();
 
     restoredValue = tizen.power.getScreenBrightness();
-    assert_not_equals(restoredValue, defaultValue, "screen brightness was not restored");
-}, "PowerManager_restoreScreenBrightness_check_effect");
+    assert_equals(restoredValue, defaultValue, "screen brightness was not restored");
+}, document.title);
+
 </script>
 </body>
 </html>
index 932066924784bf5ecaa1d3387b9e7b1d20817692..1b8fe1af7be504fd8b71976bf4e5383254c88aad 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_restoreScreenBrightness_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_restoreScreenBrightness_exist
 //==== LABEL Check if restoreScreenBrightness method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:restoreScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("restoreScreenBrightness" in tizen.power, "restoreScreenBrightness method sould be implemented");
     check_method_exists(tizen.power, "restoreScreenBrightness");
-}, "PowerManager_restoreScreenBrightness_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index cd0ed3dd36de1fc19b7e17cc2c8e38373378ace6..d378a0503c30742bd331278ed503eb1cc747ef57 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_restoreScreenBrightness_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:restoreScreenBrightness M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "restoreScreenBrightness");
-}, "PowerManager_restoreScreenBrightness_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
old mode 100755 (executable)
new mode 100644 (file)
index 5195d3e..8a7b637
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenBrightness</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,7 +31,7 @@ Authors:
 //==== TEST: PowerManager_setScreenBrightness
 //==== LABEL Check if setScreenBrightness method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA MAST MR
 var initialValue, defaultValue, currentValue, returnedValue;
 
@@ -65,7 +65,8 @@ test(function () {
     currentValue = tizen.power.getScreenBrightness();
 
     assert_equals(currentValue, defaultValue, "screen brightness was not changed");
-}, "PowerManager_setScreenBrightness");
+}, document.title);
+
 </script>
 </body>
 </html>
index c1d3170b973bccaefe170ac732a8d1cb41a85620..18093e42b82f2fc18f28a4359bbbc0eb9b1eb322 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenBrightness_brightness_TypeMismatch</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -32,7 +32,7 @@ Authors:
 //==== LABEL Check if setScreenBrightness throws exception when brightness is incorrect
 //==== PRIORITY: P2
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MC
 test(function () {
     var conversionTable, brightness, exceptionName, i;
@@ -48,7 +48,8 @@ test(function () {
                 tizen.power.setScreenBrightness(brightness);
             }, exceptionName + " should be thrown.");
     }
-}, "PowerManager_setScreenBrightness_brightness_TypeMismatch");
+}, document.title);
+
 </script>
 </body>
 </html>
index a0923ed0d125e379c383ce604906d89eb6f79733..6e5bf539e66eb402bacd8d22ab9dcb145f298f9b 100644 (file)
@@ -18,15 +18,15 @@ limitations under the License.
 
 
 Authors:
-    Krzysztof Lachacz <k.lachacz@samsung.com>
+        Krzysztof Lachacz <k.lachacz@samsung.com>
 -->
 
-<html lang="en">
+<html>
 
 <head>
-<title>Messaging/UTC_power</title>
+<title>PowerManager_setScreenBrightness_brightness_invalid_val</title>
 <meta charset="utf-8">
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 <script type="text/javascript" src="support/power_common.js"></script>
 </head>
 
@@ -35,9 +35,9 @@ Authors:
 <script type="text/javascript">
 
 //==== TEST: PowerManager_setScreenBrightness_brightness_invalid_val
-//==== LABEL check if setScreenBrightness() method doesn't set out of range screen brightness
+//==== LABEL Check if setScreenBrightness() method doesn't set out of range screen brightness
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api/tizen/application.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== PRIORITY P2
 //==== TEST_CRITERIA
 test(function () {
@@ -55,7 +55,7 @@ test(function () {
         }, "exception should be thrown");
     assert_not_equals(tizen.power.getScreenBrightness(), -1, "check if screen brightness was set out of range");
 
-}, "PowerManager_setScreenBrightness_brightness_invalid_val");
+}, document.title);
 
 </script>
 </body>
index 3814190042619943c20f828a74263b63e9a4d11b..593051cdf715ecf0cf4105857b8ba3f4fd899b83 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenBrightness_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_setScreenBrightness_exist
 //==== LABEL Check if setScreenBrightness method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("setScreenBrightness" in tizen.power, "setScreenBrightness method sould be implemented");
     check_method_exists(tizen.power, "setScreenBrightness");
-}, "PowerManager_setScreenBrightness_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index 3c39cc0aec2adf336d1158f84b5b6166dfc8929c..5db3c6d1a6aef7597b55eee2f0edf230ebfd807d 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenBrightness_missarg</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,13 +31,14 @@ Authors:
 //==== TEST: PowerManager_setScreenBrightness_missarg
 //==== LABEL Check if setScreenBrightness method called with missing non-optional argument throws an exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenBrightness M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMA
-test(function() {
-    assert_throws({ name: "TypeMismatchError" }, function () {
+test(function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.setScreenBrightness();
     }, "Method should throw an exception");
-}, "PowerManager_setScreenBrightness_missarg");
+}, document.title);
+
 </script>
 </body>
 </html>
index 71005b70a65ba27bca7251b283dfe51792111dd0..65669259d202be20d8ac0082074f45bbdd5bef82 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenStateChangeListener</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -32,13 +32,13 @@ Authors:
 //==== LABEL Check if setScreenStateChangeListener method called with non-optional arguments does what it should
 //==== ONLOAD_DELAY 90
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMINA MAST MR
 setup({timeout: 90000});
 
-var t = async_test("PowerManager_setScreenStateChangeListener", {timeout: 90000}), changeCallback, retValue = null;
+var t = async_test(document.title, {timeout: 90000}), changeCallback, retValue = null;
 
-t.step(function() {
+t.step(function () {
     changeCallback = t.step_func(function (previousState, changedState) {
         assert_not_equals(previousState, changedState, "Screen States should be different.");
         assert_equals(retValue, undefined, "setScreenStateChangeListener returns wrong value");
@@ -53,6 +53,7 @@ t.step(function() {
         tizen.power.turnScreenOn();
     }
 });
+
 </script>
 </body>
 </html>
index f4af4988a5477be452289474c4a8319955f4c745..6e6f9aed5d70156715f7e647e3768aadfcb49fd9 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenStateChangeListener_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_setScreenStateChangeListener_exist
 //==== LABEL Check if setScreenStateChangeListener method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("setScreenStateChangeListener" in tizen.power, "setScreenStateChangeListener method sould be implemented");
     check_method_exists(tizen.power, "setScreenStateChangeListener");
-}, "PowerManager_setScreenStateChangeListener_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index 4af7b5cd7a5f5a422e177eb0be3aed7f0b0580d6..c58a97af62a89e7f1d470c7f7c75a8ce30370cd2 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenStateChangeListener_listener_TypeMismatch</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -32,7 +32,7 @@ Authors:
 //==== LABEL Check if setScreenStateChangeListener throws exception when listener is incorrect
 //==== PRIORITY: P2
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MC
 test(function () {
     var conversionTable, changeCallback, exceptionName, i;
@@ -48,7 +48,8 @@ test(function () {
                 tizen.power.setScreenStateChangeListener(changeCallback);
             }, exceptionName + " should be thrown.");
     }
-}, "PowerManager_setScreenStateChangeListener_listener_TypeMismatch");
+}, document.title);
+
 </script>
 </body>
 </html>
index dc9755e1d6a254bd98c286e7d35c72db198aab86..2b2ae2ac2c6b4bfac9ea0aa5c99974d5b2f4165f 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenStateChangeListener_listener_invalid_cb</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,11 +33,11 @@ Authors:
 //==== PRIORITY: P2
 //==== ONLOAD_DELAY 90
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MTCB
 setup({timeout: 90000});
 
-var t = async_test("PowerManager_setScreenStateChangeListener_listener_invalid_cb", {timeout: 90000}),
+var t = async_test(document.title, {timeout: 90000}),
     exceptionName = "TypeMismatchError", incorrectCallback;
 
 t.step(function () {
@@ -47,13 +47,14 @@ t.step(function () {
         })
     };
 
-    assert_throws({name : exceptionName},
+    assert_throws({name: exceptionName},
         function () {
             tizen.power.setScreenStateChangeListener(incorrectCallback);
         }, exceptionName + " should be thrown - given incorrect success callback.");
 
     t.done();
 });
+
 </script>
 </body>
 </html>
index 405d9ca9d079276e146009fab2b395228f79ceba..59cfdec4410ecdd39e997e76f24c6a35e77d30fe 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_setScreenStateChangeListener_missarg</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,13 +31,14 @@ Authors:
 //==== TEST: PowerManager_setScreenStateChangeListener_missarg
 //==== LABEL Check if setScreenStateChangeListener method called with missing non-optional argument throws an exception
 //==== SPEC Tizen Web API:System:Power:PowerManager:setScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MMA
-test(function() {
-    assert_throws({ name: "TypeMismatchError" }, function () {
+test(function () {
+    assert_throws(TYPE_MISMATCH_EXCEPTION, function () {
         tizen.power.setScreenStateChangeListener();
     }, "Method should throw an exception");
-}, "PowerManager_setScreenStateChangeListener_missarg");
+}, document.title);
+
 </script>
 </body>
 </html>
index f9b5a4b847f93ca9538afa655f7fefc37407746f..0527ce6681e6e68ae2a5b3f6361e32d8df3cbceb 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOff</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_turnScreenOff
 //==== LABEL Check if turnScreenOff method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOff M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
-test(function() {
+test(function () {
     var retVal = tizen.power.turnScreenOff();
     assert_equals(retVal, undefined, "method should return nothing");
-}, "PowerManager_turnScreenOff");
+}, document.title);
+
 </script>
 </body>
 </html>
index 7136a6539aa6c9889594edb8221682de4e618ac8..7d41a37a160bf2befcee69222be5594998f0f64e 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOff_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_turnScreenOff_exist
 //==== LABEL Check if turnScreenOff method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOff M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("turnScreenOff" in tizen.power, "turnScreenOff method sould be implemented");
     check_method_exists(tizen.power, "turnScreenOff");
-}, "PowerManager_turnScreenOff_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index 06c47f0506a09e72aceb8112421ed28d4edb127a..fbd6f5cda74c8ec2dbdd6c8403e5381cea4b397c 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOff_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOff M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "turnScreenOff");
-}, "PowerManager_turnScreenOff_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
index 567ac031958380d465916b4a5917976e1632b89f..5d33fe6bed57b48c435c92dd67f71d67939dc1fe 100644 (file)
@@ -31,7 +31,7 @@ Authors:
 
 <html>
 <head>
-<title>Power Test: PowerManager_turnScreenOff_successful</title>
+<title>PowerManager_turnScreenOff_successful</title>
 <link rel="author" title="Intel" href="http://www.intel.com" />
 <link rel="help" href="https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html" />
 <meta name="flags" content="" />
@@ -43,7 +43,7 @@ Authors:
 <div id="log"></div>
 <script type="text/javascript">
 //==== TEST: PowerManager_turnScreenOff_successful
-//==== LABEL check if turnScreenOff method works correctly
+//==== LABEL Check if turnScreenOff method works correctly
 //==== EXECUTION_TYPE manual
 //==== STEP Click 'Run'
 //==== EXPECT The screen should be turned off
@@ -54,14 +54,15 @@ Authors:
 //==== TEST_CRITERIA MNA MNAST
 var powerMgr = tizen.power, isScreenOn;
 
-test(function() {
+test(function () {
     powerMgr.turnScreenOn();
     powerMgr.turnScreenOff();
 
     isScreenOn = powerMgr.isScreenOn();
     assert_false(isScreenOn, "The screen should be turned off.");
 
-}, "PowerManager_turnScreenOff_successful");
+}, document.title);
+
 </script>
 </body>
 </html>
index 0dcd1ac81ff184a698b65444296831e63cf06f8f..e06405402c5ba8ae3a543c8e3147f3b100ace9cf 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOn</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_turnScreenOn
 //==== LABEL Check if turnScreenOn method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOn M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
-test(function() {
+test(function () {
     var retVal = tizen.power.turnScreenOn();
     assert_equals(retVal, undefined, "method should return nothing");
-}, "PowerManager_turnScreenOn");
+}, document.title);
+
 </script>
 </body>
 </html>
index e9f42f29d420bc57ec2c9201694910630258c460..f59e8d08d103cb550b01c1e95052297a4102207d 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOn_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_turnScreenOn_exist
 //==== LABEL Check if turnScreenOn method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOn M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("turnScreenOn" in tizen.power, "turnScreenOn method sould be implemented");
     check_method_exists(tizen.power, "turnScreenOn");
-}, "PowerManager_turnScreenOn_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index 72189b298a8826ce102273fdb31a982c5d7786c9..34385518b91153cf5ef2b4ae0553252ec24e212d 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_turnScreenOn_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOn M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "turnScreenOn");
-}, "PowerManager_turnScreenOn_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
index 95e977294abb3d9e45f2e12798fd5bf5a0c46e6d..c169f348b287b717b1edd31b8d7972b0d3604603 100644 (file)
@@ -32,7 +32,7 @@ Authors:
 
 <html>
 <head>
-<title>Power Test: PowerManager_turnScreenOn_method_exists</title>
+<title>PowerManager_turnScreenOn_method_exists</title>
 <link rel="author" title="Intel" href="http://www.intel.com" />
 <link rel="help" href="https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html" />
 <meta name="flags" content="" />
@@ -44,15 +44,16 @@ Authors:
 <div id="log"></div>
 <script type="text/javascript">
 //==== TEST: PowerManager_turnScreenOn_method_exists
-//==== LABEL check if turnScreenOn method exists
+//==== LABEL Check if turnScreenOn method exists
 //==== SPEC Tizen Web API:System:Power:PowerManager:turnScreenOn M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 var powerMgr;
-test(function() {
+test(function () {
     powerMgr = tizen.power;
     assert_true("turnScreenOn" in powerMgr, "turnScreenOn method sould be implemented");
-}, "PowerManager_turnScreenOn_method_exists");
+}, document.title);
+
 </script>
 </body>
 </html>
index ed7ffb8769876a2f7ba358e5dd7e683e419e75bb..de547d1a039449cc41ef31b917f9e58df8595c71 100644 (file)
@@ -32,7 +32,7 @@ Authors:
 
 <html>
 <head>
-<title>Power Test: PowerManager_turnScreenOn_successul</title>
+<title>PowerManager_turnScreenOn_successful</title>
 <link rel="author" title="Intel" href="http://www.intel.com" />
 <link rel="help" href="https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html" />
 <meta name="flags" content="" />
@@ -44,7 +44,7 @@ Authors:
 <div id="log"></div>
 <script type="text/javascript">
 //==== TEST: PowerManager_turnScreenOn_successful
-//==== LABEL check if turnScreenOn method works correctly
+//==== LABEL Check if turnScreenOn method works correctly
 //==== EXECUTION_TYPE manual
 //==== STEP Click 'Run'
 //==== EXPECT The screen should be turned locked
@@ -55,22 +55,15 @@ Authors:
 //==== TEST_CRITERIA MNA MNAST
 setup({timeout: 90000});
 
-var t = async_test("PowerManager_turnScreenOn_successful", {timeout: 90000});
-
-try {
+var t = async_test(document.title, {timeout: 90000}), isScreenOn = tizen.power.isScreenOn();
+t.step(function () {
     tizen.power.turnScreenOff();
     tizen.power.turnScreenOn();
-    setTimeout(t.step_func(function() {
-        var isScreenOn = tizen.power.isScreenOn();
+    setTimeout(t.step_func(function () {
         assert_true(isScreenOn, "The screen should be turned on");
         t.done();
     }), 500);
-} catch(e) {
-    test(function() {
-        assert_false(true, "tizen.power.turnScreenOn " +
-            "Exception: " + e.message);
-    });
-}
+});
 </script>
 </body>
 </html>
index 5ffd7096c6d354b379983381034d91119425746c..15521ad5d33564ffa5087e3fab5c383ad25b636a 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_unsetScreenStateChangeListener</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_unsetScreenStateChangeListener
 //==== LABEL Check if unsetScreenStateChangeListener method called with non-optional arguments does what it should
 //==== SPEC Tizen Web API:System:Power:PowerManager:unsetScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/content.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNA MR
 test(function () {
     var retVal = tizen.power.unsetScreenStateChangeListener();
     assert_equals(retVal, undefined, "unsetScreenStateChangeListener should not return anything");
-}, "PowerManager_unsetScreenStateChangeListener");
+}, document.title);
+
 </script>
 </body>
 </html>
index 961015350f3dad07081d8ae2d8fa7287baaf4899..1723afef6fffde27ceeb351a5755ce521e6d4730 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_unsetScreenStateChangeListener_exist</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -31,12 +31,13 @@ Authors:
 //==== TEST: PowerManager_unsetScreenStateChangeListener_exist
 //==== LABEL Check if unsetScreenStateChangeListener method exists and can be overriden
 //==== SPEC Tizen Web API:System:Power:PowerManager:unsetScreenStateChangeListener M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA ME
 test(function () {
     assert_true("unsetScreenStateChangeListener" in tizen.power, "unsetScreenStateChangeListener method sould be implemented");
     check_method_exists(tizen.power, "unsetScreenStateChangeListener");
-}, "PowerManager_unsetScreenStateChangeListener_exist");
+}, document.title);
+
 </script>
 </body>
 </html>
index b2b2922ebd36f0760cfc82745aeb55d082b40f68..99c2abbcaea0aa59796e1ac3de8104908502fa14 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>PowerManager_unsetScreenStateChangeListener_extra_argument</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -33,9 +33,10 @@ Authors:
 //==== SPEC Tizen Web API:System:Power:PowerManager:unsetScreenStateChangeListener M
 //==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA MNAEX
-test(function() {
+test(function () {
     checkExtraArgument(tizen.power, "unsetScreenStateChangeListener");
-}, "PowerManager_unsetScreenStateChangeListener_extra_argument");
+}, document.title);
+
 </script>
 </body>
 </html>
index b974f15cb47e230d2414a41a850cb0bb41c11ccc..a883a3611eb2150b5354947e8eb3e7e8dc8f2531 100644 (file)
@@ -32,7 +32,7 @@ Authors:
 
 <html>
 <head>
-<title>Power Test: PowerManager_unsetScreenStateChangeListener_success</title>
+<title>PowerManager_unsetScreenStateChangeListener_successful</title>
 <link rel="author" title="Intel" href="http://www.intel.com" />
 <link rel="help" href="https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html" />
 <meta name="flags" content="" />
@@ -44,7 +44,7 @@ Authors:
 <div id="log"></div>
 <script type="text/javascript">
 //==== TEST: PowerManager_unsetScreenStateChangeListener_successful
-//==== LABEL check if unsetScreenStateChangeListener method works correctly
+//==== LABEL Check if unsetScreenStateChangeListener method works correctly
 //==== EXECUTION_TYPE manual
 //==== STEP Make sure that backlight time is 15 seconds (Settings, Display).
 //==== EXPECT (None)
@@ -57,36 +57,29 @@ Authors:
 //==== TEST_CRITERIA MNA MNAST
 setup({timeout: 90000});
 
-var t = async_test("PowerManager_unsetScreenStateChangeListener_successful", { timeout:90000 });
-var changeDetected = false;
-
-function onScreenStateChanged(previousState, changedState) {
-    t.step(function() {
-        changeDetected = true;
-        assert_unreached("OnScreenStateChanged callback shouldn't " +
-            "be invoked!");
-    });
-}
+var t = async_test(document.title, {timeout: 90000}), changeDetected = false;
+t.step(function () {
+    function onScreenStateChanged(previousState, changedState) {
+        t.step(function () {
+            changeDetected = true;
+            assert_unreached("OnScreenStateChanged callback shouldn't " +
+                "be invoked!");
+        });
+    }
 
-try {
     tizen.power.release("SCREEN");
     tizen.power.release("CPU");
     tizen.power.setScreenStateChangeListener(onScreenStateChanged);
     tizen.power.unsetScreenStateChangeListener();
     tizen.power.turnScreenOn();
-    setTimeout(function() {
-        t.step(function() {
+    setTimeout(function () {
+        t.step(function () {
             assert_false(changeDetected, "screen state change shouldn't be " +
                 "detected.");
         });
         t.done();
     }, 20000);
-} catch(e) {
-    test(function() {
-        assert_false(true, "tizen.power.setScreenStateChangeListener " +
-            "Exception: " + e.message);
-    });
-}
+});
 </script>
 </body>
 </html>
index c53a380a32950fab753e43d716d2f2fb48abadc8..a4d138396c5cce2833632c262cd417f9743ed8f2 100644 (file)
@@ -16,15 +16,15 @@ limitations under the License.
 
 
 Authors:
-    Jakub Siewierski <j.siewierski@samsung.com>
-    Marcin Kaminski <marcin.ka@samsung.com>
+        Jakub Siewierski <j.siewierski@samsung.com>
+        Marcin Kaminski <marcin.ka@samsung.com>
 
 -->
-<html lang="en">
+<html>
 <head>
 <title>ScreenStateChangeCallback_notexist</title>
 <meta charset="utf-8"/>
-<script type="text/javascript" src="../resources/unitcommon.js"></script>
+<script type="text/javascript" src="support/unitcommon.js"></script>
 </head>
 
 <body>
@@ -34,11 +34,11 @@ Authors:
 //==== LABEL Check if interface ScreenStateChangeCallback exists, it should not.
 //==== PRIORITY P3
 //==== SPEC Tizen Web API:System:Power:ScreenStateChangeCallback:ScreenStateChangeCallback U
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA CBNIO
 test(function () {
     check_no_interface_object("ScreenStateChangeCallback");
-}, "ScreenStateChangeCallback_notexist");
+}, document.title);
 
 </script>
 </body>
index e521055585ec43f118acff0d34f0f5991ee7c257..649bd01bca16064f69cbfd5c20aca2b318e377d2 100644 (file)
@@ -22,7 +22,7 @@ Authors:
 <html>
 <head>
 <title>ScreenStateChangeCallback_onchanged</title>
-<script src="../resources/unitcommon.js"></script>
+<script src="support/unitcommon.js"></script>
 <script src="support/power_common.js"></script>
 </head>
 
@@ -33,13 +33,13 @@ Authors:
 //==== LABEL Check if ContentScanSuccessCallback onchanged is called and if its arguments have proper type
 //==== ONLOAD_DELAY 90
 //==== SPEC Tizen Web API:System:Power:ScreenStateChangeCallback:onchanged M
-//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html
+//==== SPEC_URL https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html
 //==== TEST_CRITERIA CBT CBOA
 setup({timeout: 90000});
 
-var t = async_test("ScreenStateChangeCallback_onchanged", {timeout: 90000}), changeCallback;
+var t = async_test(document.title, {timeout: 90000}), changeCallback;
 
-t.step(function() {
+t.step(function () {
     changeCallback = t.step_func(function (previousState, changedState) {
         assert_type(previousState, "string", "previousState has wrong type");
         assert_type(changedState, "string", "changedState has wrong type");
@@ -58,6 +58,7 @@ t.step(function() {
         tizen.power.turnScreenOn();
     }
 });
+
 </script>
 </body>
 </html>
diff --git a/tct-power-tizen-tests/power/support/unitcommon.js b/tct-power-tizen-tests/power/support/unitcommon.js
new file mode 100644 (file)
index 0000000..9f972c1
--- /dev/null
@@ -0,0 +1,559 @@
+/*
+
+Copyright (c) 2013 Samsung Electronics Co., Ltd.
+
+Licensed under the Apache License, Version 2.0 (the License);
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+
+
+Authors:
+
+ */
+
+
+MIN_BYTE = -128;
+MAX_BYTE = 127;
+MIN_OCTET = 0;
+MAX_OCTET = 255;
+MIN_SHORT = -32768;
+MAX_SHORT = 32767;
+MIN_UNSIGNED_SHORT = 0;
+MAX_UNSIGNED_SHORT = 65535;
+MIN_LONG = -2147483648;
+MAX_LONG = 2147483647;
+MIN_UNSIGNED_LONG = 0;
+MAX_UNSIGNED_LONG = 4294967295;
+MIN_LONG_LONG = -9223372036854775808;
+MAX_LONG_LONG = 9223372036854775807;
+MIN_UNSIGNED_LONG_LONG = 0;
+MAX_UNSIGNED_LONG_LONG = 18446744073709551615;
+
+TYPE_MISMATCH_EXCEPTION = {name: 'TypeMismatchError'};
+NOT_FOUND_EXCEPTION = {name: 'NotFoundError'};
+INVALID_VALUES_EXCEPTION = {name: 'InvalidValuesError'};
+IO_EXCEPTION = {name: 'IOError'};
+SECURITY_EXCEPTION = {name: 'SecurityError'};
+
+
+(function () {
+   var head_src = document.head.innerHTML;
+   if (head_src.search(/\/testharness.js\W/) === -1) {
+       document.write('<script language="javascript" src="../resources/testharness.js"></script>\n');
+   }
+   if (head_src.search(/\/testharnessreport.js\W/) === -1) {
+       document.write('<script language="javascript" src="../resources/testharnessreport.js"></script>\n');
+   }
+})();
+
+var _registered_types = {};
+
+function _resolve_registered_type(type) {
+    while (type in _registered_types) {
+        type = _registered_types[type];
+    }
+    return type;
+}
+
+/**
+ * Method checks extra argument for none argument method.
+ * The only check is that method will not throw an exception.
+ * Example usage:
+ * checkExtraArgument(tizen.notification, "removeAll");
+ *
+ * @param object object
+ * @param methodName string - name of the method
+ */
+function checkExtraArgument(object, methodName) {
+    var extraArgument = [
+        null,
+        undefined,
+        "Tizen",
+        1,
+        false,
+        ["one", "two"],
+        {argument: 1},
+        function () {}
+    ], i;
+
+    for (i = 0; i < extraArgument.length; i++) {
+        object[methodName](extraArgument[i]);
+    }
+}
+
+/**
+ * Method to validate conversion.
+ * Example usage:
+ *   conversionTable = getTypeConversionExceptions("functionObject", true);
+ *   for(i = 0; i < conversionTable.length; i++) {
+ *       errorCallback = conversionTable[i][0];
+ *       exceptionName = conversionTable[i][1];
+ *
+ *       assert_throws({name : exceptionName},
+ *       function () {
+ *           tizen.systemsetting.setProperty("HOME_SCREEN",
+ *               propertyValue, successCallback, errorCallback);
+ *       }, exceptionName + " should be thrown - given incorrect errorCallback.");
+ *   }
+ *
+ * @param conversionType
+ * @param isOptional
+ * @returns table of tables which contain value (index 0) and exceptionName (index 1)
+ *
+ */
+function getTypeConversionExceptions(conversionType, isOptional) {
+    var exceptionName = "TypeMismatchError",
+        conversionTable;
+    switch (conversionType) {
+        case "enum":
+            conversionTable = [
+                [undefined, exceptionName],
+                [null, exceptionName],
+                [0, exceptionName],
+                [true, exceptionName],
+                ["dummyInvalidEnumValue", exceptionName],
+                [{ }, exceptionName]
+            ];
+            break;
+        case "double":
+            conversionTable = [
+                [undefined, exceptionName],
+                [NaN, exceptionName],
+                [Number.POSITIVE_INFINITY, exceptionName],
+                [Number.NEGATIVE_INFINITY, exceptionName],
+                ["TIZEN", exceptionName],
+                [{ name : "TIZEN" }, exceptionName],
+                [function () { }, exceptionName]
+            ];
+            break;
+        case "object":
+            conversionTable = [
+                [true, exceptionName],
+                [false, exceptionName],
+                [NaN, exceptionName],
+                [0, exceptionName],
+                ["", exceptionName],
+                ["TIZEN", exceptionName],
+                [undefined, exceptionName]
+            ];
+            if (!isOptional) {
+                conversionTable.push([null, exceptionName]);
+            }
+            break;
+        case "functionObject":
+            conversionTable = [
+                [true, exceptionName],
+                [false, exceptionName],
+                [NaN, exceptionName],
+                [0, exceptionName],
+                ["", exceptionName],
+                ["TIZEN", exceptionName],
+                [[], exceptionName],
+                [{ }, exceptionName],
+                [undefined, exceptionName]
+            ];
+            if (!isOptional) {
+                conversionTable.push([null, exceptionName]);
+            }
+            break;
+        case "array":
+            conversionTable = [
+                [true, exceptionName],
+                [false, exceptionName],
+                [NaN, exceptionName],
+                [0, exceptionName],
+                ["", exceptionName],
+                ["TIZEN", exceptionName],
+                [{ }, exceptionName],
+                [function () { }, exceptionName],
+                [undefined, exceptionName]
+            ];
+            if (!isOptional) {
+                conversionTable.push([null, exceptionName]);
+            }
+            break;
+        case "dictionary":
+            conversionTable = [
+                [true, exceptionName],
+                [false, exceptionName],
+                [NaN, exceptionName],
+                [0, exceptionName],
+                ["", exceptionName],
+                ["TIZEN", exceptionName],
+                [undefined, exceptionName]
+            ];
+            if (!isOptional) {
+                conversionTable.push([null, exceptionName]);
+            }
+            break;
+        default:
+            assert_unreached("Fix your test. Wrong conversionType '" + conversionType + "'.");
+    };
+
+    return conversionTable;
+}
+
+
+function assert_type(obj, type, description) {
+    var org_type = type, prop_name, prop_type, prop_value;
+
+    type = _resolve_registered_type(type);
+
+    if (typeof (type) === 'string') {
+        type = type.toLowerCase();
+        switch (type) {
+            case 'object':
+            case 'string':
+            case 'number':
+            case 'function':
+            case 'boolean':
+            case 'undefined':
+            case 'xml':
+                assert_equals(typeof (obj), type, description);
+                break;
+            case 'null':
+                assert_true(obj === null, description);
+                break;
+            case 'array':
+                assert_true(Array.isArray(obj), description);
+                break;
+            case 'date':
+                assert_true(obj instanceof Date, description);
+                break;
+            case 'byte':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_BYTE, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_BYTE, description + " - value too high.");
+                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
+                break;
+            case 'octet':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_OCTET, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_OCTET, description + " - value too high.");
+                assert_equals(obj % 1, 0, description + " - value is not an integer.");
+                break;
+            case 'short':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_SHORT, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_SHORT, description + " - value too high.");
+                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
+                break;
+            case 'unsigned short':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_UNSIGNED_SHORT, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_UNSIGNED_SHORT, description + " - value too high.");
+                assert_equals(obj % 1, 0, description + " - value is not an integer.");
+                break;
+            case 'long':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_LONG, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_LONG, description + " - value too high.");
+                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
+                break;
+            case 'unsigned long':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_UNSIGNED_LONG, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_UNSIGNED_LONG, description + " - value too high.");
+                assert_equals(obj % 1, 0, description + " - value is not an integer.");
+                break;
+            case 'long long':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_LONG_LONG, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_LONG_LONG, description + " - value too high.");
+                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
+                break;
+            case 'unsigned long long':
+                assert_equals(typeof (obj), 'number', description);
+                assert_greater_than_equal(obj, MIN_UNSIGNED_LONG_LONG, description + " - value too low.");
+                assert_less_than_equal(obj, MAX_UNSIGNED_LONG_LONG, description + " - value too high.");
+                assert_equals(obj % 1, 0, description + " - value is not an integer.");
+                break;
+            default:
+                assert_unreached('Fix your test. Wrong type \'' + org_type + '\'');
+        }
+    } else if (typeof (type) === 'function') {
+        assert_true(obj instanceof type, description);
+    } else if (typeof (type) === 'object') {
+        for (prop_name in type) {
+            prop_type = type[prop_name];
+            if (prop_type === 'function') {
+                assert_inherits(obj, prop_name);
+                assert_equals(typeof obj[prop_name], prop_type, 'Object should have method ' + prop_name);
+            } else {
+                assert_own_property(obj, prop_name);
+            }
+        }
+    } else {
+        assert_unreached('Fix your test. Wrong type ' + org_type);
+    }
+}
+
+function register_type(alias, type_spec) {
+    _registered_types[alias] = type_spec;
+}
+
+/**
+ * Method to check if attribute is const.
+ * Example usage:
+ * check_const(tizen.bluetooth.deviceMinor, 'TOY_DOLL', 0x03, 'number', 0x29B);
+ *
+ * @param obj  object to test which  has const attribute
+ * @param attributeName attribute name.
+ * @param expectedValue expected value of provided attribute name
+ * @param expectedType expected type of provided attribute name
+ * @param valueToAssign value to assign in order to check if attribute value can be modified
+ */
+function check_const(obj, attributeName, expectedValue, expectedType, valueToAssign) {
+    var tmp;
+    if (expectedValue === valueToAssign) {
+        assert_unreached("Fix your test. The same values given for "  + attributeName +
+            " in 'value' and 'valueToSet' arguments.");
+    }
+    if (typeof (attributeName) === "string") {
+        assert_true(attributeName in obj, "Name " + attributeName + " doesn't exist in provided object.");
+        assert_equals(obj[attributeName], expectedValue, "Value of " + attributeName + " is diffrent.");
+        if (typeof (expectedType) !== "undefined") {
+            if (expectedValue === null) {
+                assert_type(obj[attributeName], "object", "Type of " + attributeName + " is different.");
+            } else {
+                assert_type(obj[attributeName], expectedType, "Type of " + attributeName + " is different.");
+            }
+        } else {
+            assert_unreached("Fix your test. Wrong type " + expectedType);
+        }
+        tmp = obj[attributeName];
+        obj[attributeName] = valueToAssign;
+        assert_equals(obj[attributeName], tmp, attributeName + " can be modified.");
+    } else {
+        assert_unreached("Fix your test. Wrong type of name " + typeof (attributeName));
+    }
+}
+
+/**
+ * Method to check if attribute is readonly.
+ * Example usage:
+ * check_readonly(statusNotification, "postedTime", null, 'object', new Date());
+ *
+ * @param obj  object to test which  has readonly attribute
+ * @param attributeName attribute name.
+ * @param expectedValue expected value of provided attribute name
+ * @param expectedType expected type of provided attribute name
+ * @param valueToAssign value to assign in order to check if attribute value can be modified
+ */
+function check_readonly(obj, attributeName, expectedValue, expectedType, valueToAssign) {
+    check_const(obj, attributeName, expectedValue, expectedType, valueToAssign);
+}
+
+/**
+ * Method to check if attribute can be set to null.
+ * Example usage:
+ * check_not_nullable(syncInfo, "mode");
+ *
+ * @param obj object to test which has not nullable attribute
+ * @param attributeName attribute name.
+ */
+function check_not_nullable(obj, attributeName)
+{   var old_value = obj[attributeName];
+    obj[attributeName] = null;
+    assert_not_equals(obj[attributeName], null, "Attribute " + attributeName + " can be set to null.");
+    obj[attributeName] = old_value;
+}
+
+/**
+ * Method to check NoInterfaceObject
+ * Example usage:
+ * check_no_interface_object("BluetoothAdapter")
+ *
+ * @param interfaceName interface name
+ */
+function check_no_interface_object(interfaceName) {
+    assert_throws({name: "TypeError"}, function () {
+        tizen[interfaceName]();
+    },"Wrong call as a function");
+    assert_throws({name: "TypeError"}, function () {
+        new tizen[interfaceName]();
+    },"Wrong call as a new function");
+    assert_throws({name: "TypeError"}, function () {
+        ({}) instanceof tizen[interfaceName];
+    },"instanceof exception");
+    assert_equals(tizen[interfaceName], undefined, interfaceName + " is not undefined.");
+}
+
+
+/**
+ * Method to check Constructors
+ * Example usage:
+ * check_constructor("BluetoothAdapter")
+ *
+ * @param constructorName constructor name
+ */
+
+function check_constructor(constructorName) {
+    assert_true(constructorName in tizen, "No " + constructorName + " in tizen.");
+    assert_false({} instanceof tizen[constructorName],"Custom object is not instance of " + constructorName);
+    assert_throws({
+        name: "TypeError"
+    }, function () {
+        tizen[constructorName]();
+    }, "Constructor called as function.");
+}
+
+/**
+ * Method to check if given method can be overridden in a given object - (TEMPORARY REMOVED).
+ * That method also checks if given method exists in a given object.
+ * Example usage:
+ * check_method_exists(tizen.notification, "get");
+ *
+ * @param obj object with method
+ * @param methodName name of the method to check.
+ */
+function check_method_exists(obj, methodName) {
+    assert_type(obj[methodName], 'function', "Method does not exist.");
+}
+
+/**
+ * Method to check extensibility of given object.
+ * Method checks if new attribute and method can be added.
+ * Example usage:
+ * check_extensibility(tizen.notification);
+ *
+ * @param obj object to check
+ */
+function check_extensibility(obj) {
+    var dummyAttribute = "dummyAttributeValue", dummyMethodResult = "dummyMethodResultValue";
+    obj.newDummyMethod = function() {
+        return dummyMethodResult;
+    }
+    assert_equals(obj.newDummyMethod(), dummyMethodResult, "Incorrect result from added method.");
+
+    obj.newDummyAttribute = dummyAttribute;
+    assert_equals(obj.newDummyAttribute, dummyAttribute, "Incorrect result from added attribute.");
+}
+
+/**
+ * Method to check if attribute can be modify.
+ * Example usage:
+ * check_attr(downloadRequest, "fileName", default_val, "string", "file_name.html");
+ *
+ * @param obj  object to test which has not readonly attribute
+ * @param attributeName attribute name.
+ * @param expectedValue expected value of provided attribute name
+ * @param expectedType expected type of provided attribute name
+ * @param valueToAssign value to assign in order to check if attribute value can be modified
+ */
+function check_attribute(obj, attributeName, expectedValue, expectedType, valueToAssign) {
+    if (expectedValue === valueToAssign) {
+        assert_unreached("Fix your test. The same values given for "  + attributeName +
+            " in 'value' and 'valueToSet' arguments.");
+    }
+    if (typeof (attributeName) === "string") {
+        assert_true(attributeName in obj, "Name " + attributeName + " doesn't exist in provided object.");
+        assert_equals(obj[attributeName], expectedValue, "Value of " + attributeName + " is diffrent.");
+        if (typeof (expectedType) !== "undefined") {
+            if (expectedValue === null) {
+                assert_type(obj[attributeName], "object", "Type of " + attributeName + " is different.");
+            } else {
+                assert_type(obj[attributeName], expectedType, "Type of " + attributeName + " is different.");
+            }
+        } else {
+            assert_unreached("Fix your test. Wrong type " + expectedType);
+        }
+        obj[attributeName] = valueToAssign;
+        assert_equals(obj[attributeName], valueToAssign, attributeName + " can be modified.");
+    } else {
+        assert_unreached("Fix your test. Wrong type of name " + typeof (attributeName));
+    }
+}
+
+/**
+ * Method to check if whole array can be overwritten with an invalid value.
+ * Sample usage:
+ * check_invalid_array_assignments(message, "to", false);
+ *
+ * @param obj object which has the array as its property
+ * @param array name of the array to check
+ * @param isNullable indicates if the array can be null
+ */
+function check_invalid_array_assignments(obj, array, isNullable) {
+    var args = [undefined, true, false, NaN, 0, "TIZEN", {}, function () {}],
+        val = obj[array], i;
+
+    if (!isNullable) {
+        obj[array] = null;
+        assert_not_equals(obj[array], null, "Non-nullable array was set to null");
+        assert_type(obj[array], "array", "Non-nullable array type changed after assigning null");
+        assert_equals(obj[array].toString(), val.toString(), "Non-nullable array contents changed after assigning null");
+    }
+
+    for (i = 0 ; i < args.length ; i++) {
+        obj[array] = args[i];
+        assert_type(obj[array], "array", "Array type changed after assigning an invalid value");
+        assert_equals(obj[array].toString(), val.toString(), "Array contents changed after assigning an invalid value");
+    }
+}
+
+/**
+ * Method to check if an object can be overwritten with an invalid value.
+ * Sample usage:
+ * check_invalid_object_assignments(message, "body", false);
+ *
+ * @param parentObj object which has the 'obj' object as its property
+ * @param obj name of the object to check
+ * @param isNullable indicates if the object can be null
+ */
+function check_invalid_obj_assignments(parentObj, obj, isNullable) {
+    var args = [undefined, true, false, NaN, 0, "TIZEN", function () {}],
+        val = parentObj[obj], i;
+
+    if (!isNullable) {
+        parentObj[obj] = null;
+        assert_equals(parentObj[obj], val, "Non-nullable obj was modified after assigning null");
+    }
+
+    for (i = 0 ; i < args.length ; i++) {
+        parentObj[obj] = args[i];
+        assert_equals(parentObj[obj], val, "The object was set to " + args[i]);
+    }
+}
+
+/**
+ * Method to validate conversion for listeners.
+ * Example usage:
+ * incorrectListeners = getListenerConversionExceptions(["oninstalled", "onupdated", "onuninstalled"]);
+ * for(i = 0; i < incorrectListeners.length; i++) {
+ *     packageInformationEventCallback  = incorrectListeners[i][0];
+ *     exceptionName = incorrectListeners[i][1];
+ *     assert_throws({name : exceptionName},
+ *        function () {
+ *             tizen.package.setPackageInfoEventListener(packageInformationEventCallback);
+ *         }, exceptionName + " should be thrown - given incorrect successCallback.");
+ * }
+ *
+ *
+ * @param callbackNames Array with names
+ * @returns {Array} table of tables which contain incorrect listener (index 0) and exceptionName (index 1)
+ *
+ */
+function getListenerConversionExceptions(callbackNames) {
+    var result = [], conversionTable, i, j, listenerName;
+    conversionTable = getTypeConversionExceptions("functionObject", false);
+
+    for (i = 0; i < callbackNames.length; i++) {
+        for (j = 0; j < conversionTable.length; j++) {
+            listenerName = {};
+            listenerName[callbackNames[i]] = conversionTable[j][0];
+            result.push([listenerName, conversionTable[j][1]]);
+        }
+    }
+
+    return result;
+}
diff --git a/tct-power-tizen-tests/resources/unitcommon.js b/tct-power-tizen-tests/resources/unitcommon.js
deleted file mode 100644 (file)
index 9f972c1..0000000
+++ /dev/null
@@ -1,559 +0,0 @@
-/*
-
-Copyright (c) 2013 Samsung Electronics Co., Ltd.
-
-Licensed under the Apache License, Version 2.0 (the License);
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
-    http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-
-
-
-Authors:
-
- */
-
-
-MIN_BYTE = -128;
-MAX_BYTE = 127;
-MIN_OCTET = 0;
-MAX_OCTET = 255;
-MIN_SHORT = -32768;
-MAX_SHORT = 32767;
-MIN_UNSIGNED_SHORT = 0;
-MAX_UNSIGNED_SHORT = 65535;
-MIN_LONG = -2147483648;
-MAX_LONG = 2147483647;
-MIN_UNSIGNED_LONG = 0;
-MAX_UNSIGNED_LONG = 4294967295;
-MIN_LONG_LONG = -9223372036854775808;
-MAX_LONG_LONG = 9223372036854775807;
-MIN_UNSIGNED_LONG_LONG = 0;
-MAX_UNSIGNED_LONG_LONG = 18446744073709551615;
-
-TYPE_MISMATCH_EXCEPTION = {name: 'TypeMismatchError'};
-NOT_FOUND_EXCEPTION = {name: 'NotFoundError'};
-INVALID_VALUES_EXCEPTION = {name: 'InvalidValuesError'};
-IO_EXCEPTION = {name: 'IOError'};
-SECURITY_EXCEPTION = {name: 'SecurityError'};
-
-
-(function () {
-   var head_src = document.head.innerHTML;
-   if (head_src.search(/\/testharness.js\W/) === -1) {
-       document.write('<script language="javascript" src="../resources/testharness.js"></script>\n');
-   }
-   if (head_src.search(/\/testharnessreport.js\W/) === -1) {
-       document.write('<script language="javascript" src="../resources/testharnessreport.js"></script>\n');
-   }
-})();
-
-var _registered_types = {};
-
-function _resolve_registered_type(type) {
-    while (type in _registered_types) {
-        type = _registered_types[type];
-    }
-    return type;
-}
-
-/**
- * Method checks extra argument for none argument method.
- * The only check is that method will not throw an exception.
- * Example usage:
- * checkExtraArgument(tizen.notification, "removeAll");
- *
- * @param object object
- * @param methodName string - name of the method
- */
-function checkExtraArgument(object, methodName) {
-    var extraArgument = [
-        null,
-        undefined,
-        "Tizen",
-        1,
-        false,
-        ["one", "two"],
-        {argument: 1},
-        function () {}
-    ], i;
-
-    for (i = 0; i < extraArgument.length; i++) {
-        object[methodName](extraArgument[i]);
-    }
-}
-
-/**
- * Method to validate conversion.
- * Example usage:
- *   conversionTable = getTypeConversionExceptions("functionObject", true);
- *   for(i = 0; i < conversionTable.length; i++) {
- *       errorCallback = conversionTable[i][0];
- *       exceptionName = conversionTable[i][1];
- *
- *       assert_throws({name : exceptionName},
- *       function () {
- *           tizen.systemsetting.setProperty("HOME_SCREEN",
- *               propertyValue, successCallback, errorCallback);
- *       }, exceptionName + " should be thrown - given incorrect errorCallback.");
- *   }
- *
- * @param conversionType
- * @param isOptional
- * @returns table of tables which contain value (index 0) and exceptionName (index 1)
- *
- */
-function getTypeConversionExceptions(conversionType, isOptional) {
-    var exceptionName = "TypeMismatchError",
-        conversionTable;
-    switch (conversionType) {
-        case "enum":
-            conversionTable = [
-                [undefined, exceptionName],
-                [null, exceptionName],
-                [0, exceptionName],
-                [true, exceptionName],
-                ["dummyInvalidEnumValue", exceptionName],
-                [{ }, exceptionName]
-            ];
-            break;
-        case "double":
-            conversionTable = [
-                [undefined, exceptionName],
-                [NaN, exceptionName],
-                [Number.POSITIVE_INFINITY, exceptionName],
-                [Number.NEGATIVE_INFINITY, exceptionName],
-                ["TIZEN", exceptionName],
-                [{ name : "TIZEN" }, exceptionName],
-                [function () { }, exceptionName]
-            ];
-            break;
-        case "object":
-            conversionTable = [
-                [true, exceptionName],
-                [false, exceptionName],
-                [NaN, exceptionName],
-                [0, exceptionName],
-                ["", exceptionName],
-                ["TIZEN", exceptionName],
-                [undefined, exceptionName]
-            ];
-            if (!isOptional) {
-                conversionTable.push([null, exceptionName]);
-            }
-            break;
-        case "functionObject":
-            conversionTable = [
-                [true, exceptionName],
-                [false, exceptionName],
-                [NaN, exceptionName],
-                [0, exceptionName],
-                ["", exceptionName],
-                ["TIZEN", exceptionName],
-                [[], exceptionName],
-                [{ }, exceptionName],
-                [undefined, exceptionName]
-            ];
-            if (!isOptional) {
-                conversionTable.push([null, exceptionName]);
-            }
-            break;
-        case "array":
-            conversionTable = [
-                [true, exceptionName],
-                [false, exceptionName],
-                [NaN, exceptionName],
-                [0, exceptionName],
-                ["", exceptionName],
-                ["TIZEN", exceptionName],
-                [{ }, exceptionName],
-                [function () { }, exceptionName],
-                [undefined, exceptionName]
-            ];
-            if (!isOptional) {
-                conversionTable.push([null, exceptionName]);
-            }
-            break;
-        case "dictionary":
-            conversionTable = [
-                [true, exceptionName],
-                [false, exceptionName],
-                [NaN, exceptionName],
-                [0, exceptionName],
-                ["", exceptionName],
-                ["TIZEN", exceptionName],
-                [undefined, exceptionName]
-            ];
-            if (!isOptional) {
-                conversionTable.push([null, exceptionName]);
-            }
-            break;
-        default:
-            assert_unreached("Fix your test. Wrong conversionType '" + conversionType + "'.");
-    };
-
-    return conversionTable;
-}
-
-
-function assert_type(obj, type, description) {
-    var org_type = type, prop_name, prop_type, prop_value;
-
-    type = _resolve_registered_type(type);
-
-    if (typeof (type) === 'string') {
-        type = type.toLowerCase();
-        switch (type) {
-            case 'object':
-            case 'string':
-            case 'number':
-            case 'function':
-            case 'boolean':
-            case 'undefined':
-            case 'xml':
-                assert_equals(typeof (obj), type, description);
-                break;
-            case 'null':
-                assert_true(obj === null, description);
-                break;
-            case 'array':
-                assert_true(Array.isArray(obj), description);
-                break;
-            case 'date':
-                assert_true(obj instanceof Date, description);
-                break;
-            case 'byte':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_BYTE, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_BYTE, description + " - value too high.");
-                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
-                break;
-            case 'octet':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_OCTET, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_OCTET, description + " - value too high.");
-                assert_equals(obj % 1, 0, description + " - value is not an integer.");
-                break;
-            case 'short':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_SHORT, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_SHORT, description + " - value too high.");
-                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
-                break;
-            case 'unsigned short':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_UNSIGNED_SHORT, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_UNSIGNED_SHORT, description + " - value too high.");
-                assert_equals(obj % 1, 0, description + " - value is not an integer.");
-                break;
-            case 'long':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_LONG, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_LONG, description + " - value too high.");
-                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
-                break;
-            case 'unsigned long':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_UNSIGNED_LONG, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_UNSIGNED_LONG, description + " - value too high.");
-                assert_equals(obj % 1, 0, description + " - value is not an integer.");
-                break;
-            case 'long long':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_LONG_LONG, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_LONG_LONG, description + " - value too high.");
-                assert_equals(Math.abs(obj % 1), 0, description + " - value is not an integer.");
-                break;
-            case 'unsigned long long':
-                assert_equals(typeof (obj), 'number', description);
-                assert_greater_than_equal(obj, MIN_UNSIGNED_LONG_LONG, description + " - value too low.");
-                assert_less_than_equal(obj, MAX_UNSIGNED_LONG_LONG, description + " - value too high.");
-                assert_equals(obj % 1, 0, description + " - value is not an integer.");
-                break;
-            default:
-                assert_unreached('Fix your test. Wrong type \'' + org_type + '\'');
-        }
-    } else if (typeof (type) === 'function') {
-        assert_true(obj instanceof type, description);
-    } else if (typeof (type) === 'object') {
-        for (prop_name in type) {
-            prop_type = type[prop_name];
-            if (prop_type === 'function') {
-                assert_inherits(obj, prop_name);
-                assert_equals(typeof obj[prop_name], prop_type, 'Object should have method ' + prop_name);
-            } else {
-                assert_own_property(obj, prop_name);
-            }
-        }
-    } else {
-        assert_unreached('Fix your test. Wrong type ' + org_type);
-    }
-}
-
-function register_type(alias, type_spec) {
-    _registered_types[alias] = type_spec;
-}
-
-/**
- * Method to check if attribute is const.
- * Example usage:
- * check_const(tizen.bluetooth.deviceMinor, 'TOY_DOLL', 0x03, 'number', 0x29B);
- *
- * @param obj  object to test which  has const attribute
- * @param attributeName attribute name.
- * @param expectedValue expected value of provided attribute name
- * @param expectedType expected type of provided attribute name
- * @param valueToAssign value to assign in order to check if attribute value can be modified
- */
-function check_const(obj, attributeName, expectedValue, expectedType, valueToAssign) {
-    var tmp;
-    if (expectedValue === valueToAssign) {
-        assert_unreached("Fix your test. The same values given for "  + attributeName +
-            " in 'value' and 'valueToSet' arguments.");
-    }
-    if (typeof (attributeName) === "string") {
-        assert_true(attributeName in obj, "Name " + attributeName + " doesn't exist in provided object.");
-        assert_equals(obj[attributeName], expectedValue, "Value of " + attributeName + " is diffrent.");
-        if (typeof (expectedType) !== "undefined") {
-            if (expectedValue === null) {
-                assert_type(obj[attributeName], "object", "Type of " + attributeName + " is different.");
-            } else {
-                assert_type(obj[attributeName], expectedType, "Type of " + attributeName + " is different.");
-            }
-        } else {
-            assert_unreached("Fix your test. Wrong type " + expectedType);
-        }
-        tmp = obj[attributeName];
-        obj[attributeName] = valueToAssign;
-        assert_equals(obj[attributeName], tmp, attributeName + " can be modified.");
-    } else {
-        assert_unreached("Fix your test. Wrong type of name " + typeof (attributeName));
-    }
-}
-
-/**
- * Method to check if attribute is readonly.
- * Example usage:
- * check_readonly(statusNotification, "postedTime", null, 'object', new Date());
- *
- * @param obj  object to test which  has readonly attribute
- * @param attributeName attribute name.
- * @param expectedValue expected value of provided attribute name
- * @param expectedType expected type of provided attribute name
- * @param valueToAssign value to assign in order to check if attribute value can be modified
- */
-function check_readonly(obj, attributeName, expectedValue, expectedType, valueToAssign) {
-    check_const(obj, attributeName, expectedValue, expectedType, valueToAssign);
-}
-
-/**
- * Method to check if attribute can be set to null.
- * Example usage:
- * check_not_nullable(syncInfo, "mode");
- *
- * @param obj object to test which has not nullable attribute
- * @param attributeName attribute name.
- */
-function check_not_nullable(obj, attributeName)
-{   var old_value = obj[attributeName];
-    obj[attributeName] = null;
-    assert_not_equals(obj[attributeName], null, "Attribute " + attributeName + " can be set to null.");
-    obj[attributeName] = old_value;
-}
-
-/**
- * Method to check NoInterfaceObject
- * Example usage:
- * check_no_interface_object("BluetoothAdapter")
- *
- * @param interfaceName interface name
- */
-function check_no_interface_object(interfaceName) {
-    assert_throws({name: "TypeError"}, function () {
-        tizen[interfaceName]();
-    },"Wrong call as a function");
-    assert_throws({name: "TypeError"}, function () {
-        new tizen[interfaceName]();
-    },"Wrong call as a new function");
-    assert_throws({name: "TypeError"}, function () {
-        ({}) instanceof tizen[interfaceName];
-    },"instanceof exception");
-    assert_equals(tizen[interfaceName], undefined, interfaceName + " is not undefined.");
-}
-
-
-/**
- * Method to check Constructors
- * Example usage:
- * check_constructor("BluetoothAdapter")
- *
- * @param constructorName constructor name
- */
-
-function check_constructor(constructorName) {
-    assert_true(constructorName in tizen, "No " + constructorName + " in tizen.");
-    assert_false({} instanceof tizen[constructorName],"Custom object is not instance of " + constructorName);
-    assert_throws({
-        name: "TypeError"
-    }, function () {
-        tizen[constructorName]();
-    }, "Constructor called as function.");
-}
-
-/**
- * Method to check if given method can be overridden in a given object - (TEMPORARY REMOVED).
- * That method also checks if given method exists in a given object.
- * Example usage:
- * check_method_exists(tizen.notification, "get");
- *
- * @param obj object with method
- * @param methodName name of the method to check.
- */
-function check_method_exists(obj, methodName) {
-    assert_type(obj[methodName], 'function', "Method does not exist.");
-}
-
-/**
- * Method to check extensibility of given object.
- * Method checks if new attribute and method can be added.
- * Example usage:
- * check_extensibility(tizen.notification);
- *
- * @param obj object to check
- */
-function check_extensibility(obj) {
-    var dummyAttribute = "dummyAttributeValue", dummyMethodResult = "dummyMethodResultValue";
-    obj.newDummyMethod = function() {
-        return dummyMethodResult;
-    }
-    assert_equals(obj.newDummyMethod(), dummyMethodResult, "Incorrect result from added method.");
-
-    obj.newDummyAttribute = dummyAttribute;
-    assert_equals(obj.newDummyAttribute, dummyAttribute, "Incorrect result from added attribute.");
-}
-
-/**
- * Method to check if attribute can be modify.
- * Example usage:
- * check_attr(downloadRequest, "fileName", default_val, "string", "file_name.html");
- *
- * @param obj  object to test which has not readonly attribute
- * @param attributeName attribute name.
- * @param expectedValue expected value of provided attribute name
- * @param expectedType expected type of provided attribute name
- * @param valueToAssign value to assign in order to check if attribute value can be modified
- */
-function check_attribute(obj, attributeName, expectedValue, expectedType, valueToAssign) {
-    if (expectedValue === valueToAssign) {
-        assert_unreached("Fix your test. The same values given for "  + attributeName +
-            " in 'value' and 'valueToSet' arguments.");
-    }
-    if (typeof (attributeName) === "string") {
-        assert_true(attributeName in obj, "Name " + attributeName + " doesn't exist in provided object.");
-        assert_equals(obj[attributeName], expectedValue, "Value of " + attributeName + " is diffrent.");
-        if (typeof (expectedType) !== "undefined") {
-            if (expectedValue === null) {
-                assert_type(obj[attributeName], "object", "Type of " + attributeName + " is different.");
-            } else {
-                assert_type(obj[attributeName], expectedType, "Type of " + attributeName + " is different.");
-            }
-        } else {
-            assert_unreached("Fix your test. Wrong type " + expectedType);
-        }
-        obj[attributeName] = valueToAssign;
-        assert_equals(obj[attributeName], valueToAssign, attributeName + " can be modified.");
-    } else {
-        assert_unreached("Fix your test. Wrong type of name " + typeof (attributeName));
-    }
-}
-
-/**
- * Method to check if whole array can be overwritten with an invalid value.
- * Sample usage:
- * check_invalid_array_assignments(message, "to", false);
- *
- * @param obj object which has the array as its property
- * @param array name of the array to check
- * @param isNullable indicates if the array can be null
- */
-function check_invalid_array_assignments(obj, array, isNullable) {
-    var args = [undefined, true, false, NaN, 0, "TIZEN", {}, function () {}],
-        val = obj[array], i;
-
-    if (!isNullable) {
-        obj[array] = null;
-        assert_not_equals(obj[array], null, "Non-nullable array was set to null");
-        assert_type(obj[array], "array", "Non-nullable array type changed after assigning null");
-        assert_equals(obj[array].toString(), val.toString(), "Non-nullable array contents changed after assigning null");
-    }
-
-    for (i = 0 ; i < args.length ; i++) {
-        obj[array] = args[i];
-        assert_type(obj[array], "array", "Array type changed after assigning an invalid value");
-        assert_equals(obj[array].toString(), val.toString(), "Array contents changed after assigning an invalid value");
-    }
-}
-
-/**
- * Method to check if an object can be overwritten with an invalid value.
- * Sample usage:
- * check_invalid_object_assignments(message, "body", false);
- *
- * @param parentObj object which has the 'obj' object as its property
- * @param obj name of the object to check
- * @param isNullable indicates if the object can be null
- */
-function check_invalid_obj_assignments(parentObj, obj, isNullable) {
-    var args = [undefined, true, false, NaN, 0, "TIZEN", function () {}],
-        val = parentObj[obj], i;
-
-    if (!isNullable) {
-        parentObj[obj] = null;
-        assert_equals(parentObj[obj], val, "Non-nullable obj was modified after assigning null");
-    }
-
-    for (i = 0 ; i < args.length ; i++) {
-        parentObj[obj] = args[i];
-        assert_equals(parentObj[obj], val, "The object was set to " + args[i]);
-    }
-}
-
-/**
- * Method to validate conversion for listeners.
- * Example usage:
- * incorrectListeners = getListenerConversionExceptions(["oninstalled", "onupdated", "onuninstalled"]);
- * for(i = 0; i < incorrectListeners.length; i++) {
- *     packageInformationEventCallback  = incorrectListeners[i][0];
- *     exceptionName = incorrectListeners[i][1];
- *     assert_throws({name : exceptionName},
- *        function () {
- *             tizen.package.setPackageInfoEventListener(packageInformationEventCallback);
- *         }, exceptionName + " should be thrown - given incorrect successCallback.");
- * }
- *
- *
- * @param callbackNames Array with names
- * @returns {Array} table of tables which contain incorrect listener (index 0) and exceptionName (index 1)
- *
- */
-function getListenerConversionExceptions(callbackNames) {
-    var result = [], conversionTable, i, j, listenerName;
-    conversionTable = getTypeConversionExceptions("functionObject", false);
-
-    for (i = 0; i < callbackNames.length; i++) {
-        for (j = 0; j < conversionTable.length; j++) {
-            listenerName = {};
-            listenerName[callbackNames[i]] = conversionTable[j][0];
-            result.push([listenerName, conversionTable[j][1]]);
-        }
-    }
-
-    return result;
-}
old mode 100755 (executable)
new mode 100644 (file)
index d29abac..9709187
@@ -17,7 +17,7 @@
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="release" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#releaseid2576878</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
@@ -41,7 +41,7 @@
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if turnScreenOff method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_turnScreenOff_successful">
+      <testcase purpose="Check if turnScreenOff method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_turnScreenOff_successful">
         <description>
           <steps>
             <step order="1">
@@ -63,7 +63,7 @@
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if turnScreenOn method exists" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_turnScreenOn_method_exists">
+      <testcase purpose="Check if turnScreenOn method exists" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_turnScreenOn_method_exists">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_turnScreenOn_method_exists.html</test_script_entry>
         </description>
@@ -75,7 +75,7 @@
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if turnScreenOn method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_turnScreenOn_successful">
+      <testcase purpose="Check if turnScreenOn method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_turnScreenOn_successful">
         <description>
           <steps>
             <step order="1">
@@ -97,7 +97,7 @@
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if unsetScreenStateChangeListener method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_unsetScreenStateChangeListener_successful">
+      <testcase purpose="Check if unsetScreenStateChangeListener method works correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_unsetScreenStateChangeListener_successful">
         <description>
           <steps>
             <step order="1">
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManagerObject" usage="true" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" usage="true" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="ScreenStateChangeCallback" usage="true" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" usage="true" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" usage="true" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="request" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="release" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#releaseid2576878</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="release" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="release" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="release" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html#requestid2576680</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="getScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="getScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="isScreenOn" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="isScreenOn" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="restoreScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="restoreScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="turnScreenOff" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="turnScreenOff" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="turnScreenOn" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="turnScreenOn" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="unsetScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/content.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="unsetScreenStateChangeListener" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
         <specs>
           <spec>
             <spec_assertion interface="ScreenStateChangeCallback" element_type="method" element_name="onchanged" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if setScreenBrightness() method doesn't set out of range screen brightness" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P2" id="PowerManager_setScreenBrightness_brightness_invalid_val">
+      <testcase purpose="Check if setScreenBrightness() method doesn't set out of range screen brightness" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P2" id="PowerManager_setScreenBrightness_brightness_invalid_val">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_setScreenBrightness_brightness_invalid_val.html</test_script_entry>
         </description>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="setScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api/tizen/application.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check whether getScreenBrightness() method gets the screen brightness level correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_getScreenBrightness_check_change">
+      <testcase purpose="Check whether getScreenBrightness() method gets the screen brightness level correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_getScreenBrightness_check_change">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_getScreenBrightness_check_change.html</test_script_entry>
         </description>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="getScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check whether isScreenOn() method gets the screen state correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_isScreenOn_check_change">
+      <testcase purpose="Check whether isScreenOn() method gets the screen state correctly" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="auto" priority="P1" id="PowerManager_isScreenOn_check_change">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_isScreenOn_check_change.html</test_script_entry>
         </description>
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="isScreenOn" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
       </testcase>
-      <testcase purpose="check if restoreScreenBrightness() method restores the screen brightness to the system default setting value" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_restoreScreenBrightness_check_effect">
+      <testcase purpose="Check if restoreScreenBrightness() method restores the screen brightness to the system default setting value" type="compliance" status="approved" component="TizenAPI/System/Power" execution_type="manual" priority="P1" id="PowerManager_restoreScreenBrightness_check_effect">
         <description>
           <steps>
             <step order="1">
         <specs>
           <spec>
             <spec_assertion interface="PowerManager" element_type="method" element_name="restoreScreenBrightness" specification="Power" section="System" category="Tizen Device API Specifications"/>
-            <spec_url>https://developer.tizen.org/help/topic/org.tizen.help.web.api.device/tizen/power.html</spec_url>
+            <spec_url>https://developer.tizen.org/help/topic/org.tizen.web.device.apireference/tizen/power.html</spec_url>
             <spec_statement>TBD</spec_statement>
           </spec>
         </specs>
old mode 100755 (executable)
new mode 100644 (file)
index 8ae694d..29a4c62
@@ -27,7 +27,7 @@
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_request.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if turnScreenOff method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_turnScreenOff_successful">
+      <testcase purpose="Check if turnScreenOff method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_turnScreenOff_successful">
         <description>
           <steps>
             <step order="1">
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_turnScreenOff_successful.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if turnScreenOn method exists" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_turnScreenOn_method_exists">
+      <testcase purpose="Check if turnScreenOn method exists" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_turnScreenOn_method_exists">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_turnScreenOn_method_exists.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if turnScreenOn method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_turnScreenOn_successful">
+      <testcase purpose="Check if turnScreenOn method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_turnScreenOn_successful">
         <description>
           <steps>
             <step order="1">
@@ -62,7 +62,7 @@
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_turnScreenOn_successful.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if unsetScreenStateChangeListener method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_unsetScreenStateChangeListener_successful">
+      <testcase purpose="Check if unsetScreenStateChangeListener method works correctly" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_unsetScreenStateChangeListener_successful">
         <description>
           <steps>
             <step order="1">
           <test_script_entry>/opt/tct-power-tizen-tests/power/ScreenStateChangeCallback_onchanged.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if setScreenBrightness() method doesn't set out of range screen brightness" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_setScreenBrightness_brightness_invalid_val">
+      <testcase purpose="Check if setScreenBrightness() method doesn't set out of range screen brightness" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_setScreenBrightness_brightness_invalid_val">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_setScreenBrightness_brightness_invalid_val.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check whether getScreenBrightness() method gets the screen brightness level correctly" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_getScreenBrightness_check_change">
+      <testcase purpose="Check whether getScreenBrightness() method gets the screen brightness level correctly" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_getScreenBrightness_check_change">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_getScreenBrightness_check_change.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check whether isScreenOn() method gets the screen state correctly" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_isScreenOn_check_change">
+      <testcase purpose="Check whether isScreenOn() method gets the screen state correctly" component="TizenAPI/System/Power" execution_type="auto" id="PowerManager_isScreenOn_check_change">
         <description>
           <test_script_entry>/opt/tct-power-tizen-tests/power/PowerManager_isScreenOn_check_change.html</test_script_entry>
         </description>
       </testcase>
-      <testcase purpose="check if restoreScreenBrightness() method restores the screen brightness to the system default setting value" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_restoreScreenBrightness_check_effect">
+      <testcase purpose="Check if restoreScreenBrightness() method restores the screen brightness to the system default setting value" component="TizenAPI/System/Power" execution_type="manual" id="PowerManager_restoreScreenBrightness_check_effect">
         <description>
           <steps>
             <step order="1">