Skip to content

Commit

Permalink
updating network test for first-run check of exec
Browse files Browse the repository at this point in the history
  • Loading branch information
filmaj committed Mar 29, 2012
1 parent d2fc713 commit 9af5a6a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/test.network.js
Original file line number Diff line number Diff line change
@@ -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", []);
});
Expand Down

0 comments on commit 9af5a6a

Please sign in to comment.