You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2014/08/07 22:48:37 UTC

[10/11] git commit: add longer pattern sequence for testing, change expected result for old vibrate with pattern test

add longer pattern sequence for testing, change expected result for old vibrate with pattern test


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-vibration/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-vibration/commit/ab0c239e
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-vibration/tree/ab0c239e
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-vibration/diff/ab0c239e

Branch: refs/heads/master
Commit: ab0c239e9c34f19e2c1e2f7d6fdc2df0679490d9
Parents: d93aafc
Author: Edna Morales <ed...@ednas-mbp-2.raleigh.ibm.com>
Authored: Mon Jul 21 15:41:51 2014 -0400
Committer: Edna Morales <ed...@ednas-mbp-2.raleigh.ibm.com>
Committed: Mon Jul 21 15:41:51 2014 -0400

----------------------------------------------------------------------
 test/tests.js | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-vibration/blob/ab0c239e/test/tests.js
----------------------------------------------------------------------
diff --git a/test/tests.js b/test/tests.js
index 6fd993f..7ac48d9 100644
--- a/test/tests.js
+++ b/test/tests.js
@@ -63,8 +63,8 @@ exports.defineManualTests = function (contentEl, createActionButton) {
     //old vibrate with pattern call
     var vibrateWithPatternOld = function(){
         clearLog();
-        navigator.notification.vibrateWithPattern([1000, 2000, 3000]);
-        logMessage("navigator.notification.vibrateWithPattern([1000, 2000, 3000])", "green");
+        navigator.notification.vibrateWithPattern([1000, 3000, 2000, 5000]);
+        logMessage("navigator.notification.vibrateWithPattern([1000, 3000, 2000, 5000])", "green");
     };
 
     //old cancel vibrate call
@@ -91,8 +91,8 @@ exports.defineManualTests = function (contentEl, createActionButton) {
     //vibrate with a pattern using w3c spec
     var vibrateWithPattern = function() {
         clearLog();
-        navigator.vibrate([1000, 2000, 3000]);
-        logMessage("navigator.vibrate([1000, 2000, 3000])", "green");
+        navigator.vibrate([1000, 2000, 3000, 2000, 5000]);
+        logMessage("navigator.vibrate([1000, 2000, 3000, 2000, 5000])", "green");
     };
 
     //cancel existing vibration using w3c spec navigator.vibrate(0)
@@ -126,7 +126,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
         clearLog();
         navigator.vibrate([1000, 2000, 3000, 2000, 5000, 2000, 30000]);
         vibrateOn = true;
-        logMessage("navigator.vibrate([1000, 2000, 3000, 2000, 5000, 2000, 30000]);", "green");
+        logMessage("navigator.vibrate([1000, 2000, 3000, 2000, 5000, 2000, 30000])", "green");
         timeout = setTimeout(resetVibrateOn, 45000); //if user doesn't cancel vibrate, reset vibrateOn var after 45 seconds
     };
 
@@ -156,7 +156,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
         '<div id="vibrate_old"></div>' +
         'Expected result: Vibrate once for 2.5 seconds.' +
         '<p/> <div id="vibrateWithPattern_old"></div>' +
-        'Expected result: Vibrate for 1s, pause for 2s, then vibrate for 3s.' +
+        'Expected result: Pause for 1s, vibrate for 3s, pause for 2s, vibrate for 5s.' +
         '<p/> <div id="cancelVibrate_old"></div>' +
         'Expected result: Press once to initiate vibrate for 60 seconds. Press again to cancel vibrate immediately.' +
         '<p/> <div id="cancelVibrateWithPattern_old"></div>' +
@@ -166,7 +166,7 @@ exports.defineManualTests = function (contentEl, createActionButton) {
         '<p/> <div id="vibrate_array"></div>' +
         'Expected result: Vibrate once for 3 seconds.' +
         '<p/> <div id="vibrate_with_pattern"></div>' +
-        'Expected result: Vibrate for 1s, pause for 2s, then vibrate for 3s.' +
+        'Expected result: Vibrate for 1s, pause for 2s, vibrate for 3s, pause for 2s, vibrate for 5s.' +
         '<p/> <div id="cancel_zero"></div>' +
         'Expected result: Press once to initiate vibrate for 60 seconds. Press again to cancel vibrate immediately.' +
         '<p/><div id="cancel_array"></div>' +