Created
November 20, 2010 05:31
-
-
Save dominictarr/707645 to your computer and use it in GitHub Desktop.
break async_testing.runFile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//async_testing.runfile.asynct | |
exports ['does not call onSuiteDone twice'] = function (test){ | |
var file = 'async_testing/test/test-stderr' | |
require('async_testing').runFile(file,{onSuiteDone:suiteDone}) | |
function suiteDone (status,report){ | |
console.log("suiteDone - " + status + "'" + file + "'") | |
console.log(report.stderr) | |
test.finish() | |
} | |
} | |
/* | |
if there isn't a second test, this process will exit before suiteError is called again. | |
*/ | |
exports ['does not call onSuiteDone twice2'] = function (test){ | |
require('async_testing').runFile('async_testing/test/test-all_passing',{onSuiteDone:suiteDone}) | |
function suiteDone (status,report){ | |
test.finish() | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (module == require.main) { | |
// return require('../lib/async_testing').run(process.ARGV); | |
} | |
module.exports = { | |
'test A': function(test) { | |
test.ok(true); | |
test.finish(); | |
}, | |
'test B': function(test) { | |
test.ok(true); | |
test.finish(); | |
}, | |
'test C': function(test) { | |
test.ok(true); | |
test.finish(); | |
}, | |
'test D': function(test) { | |
test.ok(true); | |
test.finish(); | |
} | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exports.stderr = function (){ | |
require('sys') //generate some stderr | |
console.error('standard error....') | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment