aboutsummaryrefslogtreecommitdiff
path: root/test/handleInput.js
diff options
context:
space:
mode:
authorGregg Caines <[email protected]>2013-08-24 18:00:40 -0700
committerGregg Caines <[email protected]>2013-08-24 18:00:40 -0700
commit0c817523ee2a74a7912250056f474156dc755100 (patch)
treeb3ac61d91440216fddc7537cf1af8090fd4b6cc8 /test/handleInput.js
parent829e407f57e6a0abb15cafd69a0983165777535b (diff)
downloadnode-coveralls-0c817523ee2a74a7912250056f474156dc755100.tar.xz
node-coveralls-0c817523ee2a74a7912250056f474156dc755100.zip
removed exec-sync. version 2.2.0 candidate
Diffstat (limited to 'test/handleInput.js')
-rw-r--r--test/handleInput.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/handleInput.js b/test/handleInput.js
index 45f0482..f06e8a4 100644
--- a/test/handleInput.js
+++ b/test/handleInput.js
@@ -9,8 +9,8 @@ describe("handleInput", function(){
sinon.restoreAll();
});
it ("throws an error when there's an error sending", function(done){
- sinon.stub(index, 'getOptions', function(){
- return {};
+ sinon.stub(index, 'getOptions', function(cb){
+ return cb(null, {});
});
sinon.stub(index, 'sendToCoveralls', function(postData, cb){
try {
@@ -25,8 +25,8 @@ describe("handleInput", function(){
index.handleInput(input);
});
it ("throws an error when there's a bad status code", function(done){
- sinon.stub(index, 'getOptions', function(){
- return {};
+ sinon.stub(index, 'getOptions', function(cb){
+ return cb(null, {});
});
sinon.stub(index, 'sendToCoveralls', function(postData, cb){
try {
@@ -41,8 +41,8 @@ describe("handleInput", function(){
index.handleInput(input);
});
it ("completes successfully when there are now errors", function(done){
- sinon.stub(index, 'getOptions', function(){
- return {};
+ sinon.stub(index, 'getOptions', function(cb){
+ return cb(null, {});
});
sinon.stub(index, 'sendToCoveralls', function(postData, cb){
cb(null, {statusCode : 200}, "body");