Permalink
Browse files

Tests clean up.

  • Loading branch information...
1 parent 2335966 commit e84ef6fb0fcc73b27136585ec8360423da8ead41 @MathieuTurcotte committed Jun 27, 2012
Showing with 7 additions and 15 deletions.
  1. +2 −5 tests/all.js
  2. +2 −5 tests/any.js
  3. +3 −5 tests/multiple.js
View
@@ -4,14 +4,11 @@
*/
var events = require('events'),
- util = require('util');
-
-var testCase = require('nodeunit').testCase,
sinon = require('sinon');
var WaitForAll = require('../lib/all');
-exports["WaitForAll"] = testCase({
+exports["WaitForAll"] = {
setUp: function(callback) {
this.clock = sinon.useFakeTimers();
callback();
@@ -97,4 +94,4 @@ exports["WaitForAll"] = testCase({
test.equal(e3.listeners('done').length, 0);
test.done();
}
-});
+};
View
@@ -4,14 +4,11 @@
*/
var events = require('events'),
- util = require('util');
-
-var testCase = require('nodeunit').testCase,
sinon = require('sinon');
var WaitForAny = require('../lib/any');
-exports["WaitForAny"] = testCase({
+exports["WaitForAny"] = {
setUp: function(callback) {
this.clock = sinon.useFakeTimers();
callback();
@@ -87,4 +84,4 @@ exports["WaitForAny"] = testCase({
test.equal(e3.listeners('done').length, 0);
test.done();
}
-});
+};
View
@@ -4,11 +4,9 @@
*/
var events = require('events'),
+ sinon = require('sinon'),
util = require('util');
-var testCase = require('nodeunit').testCase,
- sinon = require('sinon');
-
var WaitForMultiple = require('../lib/multiple');
function WaitForNothing(options) {
@@ -21,7 +19,7 @@ WaitForNothing.prototype.handleDone = function() {
this.done++;
};
-exports["WaitForMultiple"] = testCase({
+exports["WaitForMultiple"] = {
setUp: function(callback) {
this.clock = sinon.useFakeTimers();
callback();
@@ -102,4 +100,4 @@ exports["WaitForMultiple"] = testCase({
test.equal(e3.listeners('logged').length, 1);
test.done();
}
-});
+};

0 comments on commit e84ef6f

Please sign in to comment.