slightly more coherent organization of concerns

This commit is contained in:
brianleroux
2011-08-19 21:50:46 -07:00
parent 9ad78a50f7
commit 7bf8c617c3
67 changed files with 6 additions and 9 deletions
File diff suppressed because it is too large Load Diff
+12
View File
@@ -0,0 +1,12 @@
this.suite1 = {
'test one': function (test) {
test.ok(true, 'everythings ok');
setTimeout(function () {
test.done();
}, 10);
},
'apples and oranges': function (test) {
test.equal('apples', 'oranges', 'comparing apples and oranges');
test.done();
}
};
+13
View File
@@ -0,0 +1,13 @@
this.suite2 = {
'another test': function (test) {
setTimeout(function () {
// lots of assertions
test.ok(true, 'everythings ok');
test.ok(true, 'everythings ok');
test.ok(true, 'everythings ok');
test.ok(true, 'everythings ok');
test.ok(true, 'everythings ok');
test.done();
}, 10);
}
};
+16
View File
@@ -0,0 +1,16 @@
<html>
<head>
<title>Example tests</title>
<script src="nodeunit.js"></script>
<script src="suite1.js"></script>
<script src="suite2.js"></script>
</head>
<body>
<script>
nodeunit.run({
'suite1': suite1,
'suite2': suite2
});
</script>
</body>
</html>