incubator-callback-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From purplecabb...@apache.org
Subject [18/40] git commit: updating network test for first-run check of exec
Date Fri, 06 Apr 2012 01:20:42 GMT
updating network test for first-run check of exec


Project: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/commit/77d5d821
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/tree/77d5d821
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/diff/77d5d821

Branch: refs/heads/master
Commit: 77d5d8218db8286385cd9a18d770a77e685e85ef
Parents: a550e08
Author: Fil Maj <maj.fil@gmail.com>
Authored: Fri Mar 30 07:13:59 2012 +0800
Committer: Jesse MacFadyen <jesse.macfadyen@nitobi.com>
Committed: Fri Mar 30 07:26:31 2012 +0800

----------------------------------------------------------------------
 test/test.network.js |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cordova-js/blob/77d5d821/test/test.network.js
----------------------------------------------------------------------
diff --git a/test/test.network.js b/test/test.network.js
index 613f732..ee9d4c7 100644
--- a/test/test.network.js
+++ b/test/test.network.js
@@ -1,11 +1,13 @@
 describe("network", function () {
     var network,
-        exec = require('cordova/exec');
+        exec = require('cordova/exec'),
+        channel = require('cordova/channel');
        
-    it("should fire exec on first-run", function() {
+    it("should fire exec on first-run after CordovaReady fires", function() {
         exec.reset();
 
         network = require('cordova/plugin/network');
+        channel.onCordovaReady.fire();
 
         expect(exec).toHaveBeenCalledWith(jasmine.any(Function), jasmine.any(Function), "NetworkStatus",
"getConnectionInfo", []);
     });


Mime
View raw message