dap commit: better descriptions

changeset:   264:cda35cc7cd40
tag:         tip
user:        Anssi Kostiainen <anssi.kostiainen@nokia.com>
date:        Wed Oct 31 11:43:48 2012 +0100
files:       battery/tests/submissions/anssik/TODO.txt battery/tests/submissions/anssik/battery-discharging.html battery/tests/submissions/anssik/battery-plugged-in.html battery/tests/submissions/anssik/battery-unplugged.html
description:
better descriptions


diff -r 0c19463d8e6a -r cda35cc7cd40 battery/tests/submissions/anssik/TODO.txt
--- a/battery/tests/submissions/anssik/TODO.txt	Wed Oct 31 00:42:19 2012 +0100
+++ b/battery/tests/submissions/anssik/TODO.txt	Wed Oct 31 11:43:48 2012 +0100
@@ -1,5 +1,4 @@
 ---+ TODO
   
    * proper {level | chargingtime | dischargingtime}change tests
-   * async tests for *change when plugged in
    * validate tests on a real device and tweak timeouts for async tests
\ No newline at end of file
diff -r 0c19463d8e6a -r cda35cc7cd40 battery/tests/submissions/anssik/battery-discharging.html
--- a/battery/tests/submissions/anssik/battery-discharging.html	Wed Oct 31 00:42:19 2012 +0100
+++ b/battery/tests/submissions/anssik/battery-discharging.html	Wed Oct 31 11:43:48 2012 +0100
@@ -24,7 +24,6 @@
     </p>
     <div id="log"></div>
     <script>
-
     (function() {
 
       setup({ timeout: 5*60*1000 });
@@ -53,7 +52,7 @@
       w.postMessage('compute');
       w.onmessage = function (e) {
         document.querySelector('#prime').textContent = e.data;
-      }
+      };
       
       navigator.battery.onlevelchange = onlevelchange_test.step_func(function (e) {
         assert_true(navigator.battery.level < battery_level, 'The value of the level attribute must decrease, if the battery is discharging.');
diff -r 0c19463d8e6a -r cda35cc7cd40 battery/tests/submissions/anssik/battery-plugged-in.html
--- a/battery/tests/submissions/anssik/battery-plugged-in.html	Wed Oct 31 00:42:19 2012 +0100
+++ b/battery/tests/submissions/anssik/battery-plugged-in.html	Wed Oct 31 11:43:48 2012 +0100
@@ -50,7 +50,7 @@
       var onlevelchange_test = async_test('When the battery\'s level changes, must fire a levelchange event.');
       var battery_level = navigator.battery.level;
       navigator.battery.onlevelchange = onlevelchange_test.step_func(function (e) {
-        assert_true(navigator.battery.level > 0 && navigator.battery.level < 1.0, 'The value of the level attribute must >0 and <1.0');
+        assert_true(navigator.battery.level > 0 && navigator.battery.level < 1.0, 'The level attribute must be set to the current battery level scaled from 0 to 1.0.');
         onlevelchange_test.done();
       });
 
diff -r 0c19463d8e6a -r cda35cc7cd40 battery/tests/submissions/anssik/battery-unplugged.html
--- a/battery/tests/submissions/anssik/battery-unplugged.html	Wed Oct 31 00:42:19 2012 +0100
+++ b/battery/tests/submissions/anssik/battery-unplugged.html	Wed Oct 31 11:43:48 2012 +0100
@@ -50,7 +50,7 @@
       var onlevelchange_test = async_test('When the battery\'s level changes, must fire a levelchange event.');
       var battery_level = navigator.battery.level;
       navigator.battery.onlevelchange = onlevelchange_test.step_func(function (e) {
-        assert_true(navigator.battery.level > 0 && navigator.battery.level < 1.0, 'The value of the level attribute must >0 and <1.0');
+        assert_true(navigator.battery.level > 0 && navigator.battery.level < 1.0, 'The level attribute must be set to the current battery level scaled from 0 to 1.0.');
         onlevelchange_test.done();
       });
 

Received on Wednesday, 31 October 2012 10:42:06 UTC