Permalink
Browse files

update setUp and tearDown examples in README

  • Loading branch information...
caolan committed Nov 8, 2010
1 parent 27d7bdb commit 43d75258f088dd009824982eb91f83a2ad9df92f
Showing with 4 additions and 2 deletions.
  1. +4 −2 README.md
View
@@ -178,11 +178,13 @@ function, which is run after each test calls test.done():
var testCase = require('nodeunit').testCase;
module.exports = testCase({
- setUp: function () {
+ setUp: function (callback) {
this.foo = 'bar';
+ callback();
},
- tearDown: function () {
+ tearDown: function (callback) {
// clean up
+ callback();
},
test1: function (test) {
test.equals(this.foo, 'bar');

0 comments on commit 43d7525

Please sign in to comment.