[Pkg-javascript-commits] [node-coveralls] 328/332: Do not use sinon-restore but sinon

Bastien Roucariès rouca at moszumanska.debian.org
Thu Nov 9 13:54:17 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-coveralls.

commit 907985f066c8b6ff040e21d645b5cc35e59bb3cb
Author: Bastien ROUCARIÈS <roucaries.bastien at gmail.com>
Date:   Thu Sep 7 22:04:18 2017 +0200

    Do not use sinon-restore but sinon
    
    Forwarded: no
---
 package.json            | 2 +-
 test/handleInput.js     | 6 +++---
 test/logger.js          | 2 +-
 test/sendToCoveralls.js | 4 ++--
 4 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/package.json b/package.json
index 25e840d..45b2d34 100644
--- a/package.json
+++ b/package.json
@@ -42,7 +42,7 @@
     "mocha": "^3.2.0",
     "mocha-lcov-reporter": "^1.2.0",
     "should": "^9.0.2",
-    "sinon-restore": "^1.0.1",
+    "sinon": "^1.0.0",
     "snyk": "^1.23.3"
   },
   "engines": {
diff --git a/test/handleInput.js b/test/handleInput.js
index dc88902..cc51e7a 100644
--- a/test/handleInput.js
+++ b/test/handleInput.js
@@ -1,13 +1,13 @@
 var should = require('should');
-var sinon = require('sinon-restore');
+var sinon = require('sinon').sandbox.create();
 var index = require('../index');
 var fs = require('fs');
 logger = require('log-driver')({level : false});
 
 describe("handleInput", function(){
    afterEach(function() {
-        sinon.restoreAll();
-      });
+        sinon.restore();
+  });
   it ("returns an error when there's an error getting options", function(done){
     sinon.stub(index, 'getOptions', function(cb){
       return cb("some error", {}); 
diff --git a/test/logger.js b/test/logger.js
index 19767df..5430829 100644
--- a/test/logger.js
+++ b/test/logger.js
@@ -1,5 +1,5 @@
 var should = require('should');
-var sinon = require('sinon-restore');
+var sinon = require('sinon');
 var index = require('../index');
 
 describe("logger", function(){
diff --git a/test/sendToCoveralls.js b/test/sendToCoveralls.js
index 6121bbb..3589bd8 100644
--- a/test/sendToCoveralls.js
+++ b/test/sendToCoveralls.js
@@ -1,6 +1,6 @@
 var should = require('should');
 var request = require('request');
-var sinon = require('sinon-restore');
+var sinon = require('sinon').sandbox.create();
 var index = require('../index');
 logger = require('log-driver')({level : false});
 
@@ -11,7 +11,7 @@ describe("sendToCoveralls", function(){
   });
 
   afterEach(function() {
-    sinon.restoreAll();
+    sinon.restore();
     if (realCoverallsHost !== undefined) {
       process.env.COVERALLS_ENDPOINT = realCoverallsHost;
     } else {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-coveralls.git



More information about the Pkg-javascript-commits mailing list