technoweenie / ntest
- Source
- Commits
- Network (1)
- Issues (0)
- Downloads (0)
- Wiki (1)
- Graphs
-
Branch:
master
commit 75ac56b6ab1e299bf9d69e682aa0deab282f82d4
tree 6dd61f3733807c29c104cf588f6ae33c31a00f11
parent 75ccd49409aafe28c8eb71eb7eaf2ba0d56cf011
tree 6dd61f3733807c29c104cf588f6ae33c31a00f11
parent 75ccd49409aafe28c8eb71eb7eaf2ba0d56cf011
ntest /
| name | age | message | |
|---|---|---|---|
| |
LICENSE | Fri Jan 08 15:59:47 -0800 2010 | |
| |
README.md | Fri Jan 08 16:15:02 -0800 2010 | |
| |
lib/ | Fri Jan 15 06:50:03 -0800 2010 | |
| |
ntest.js | Fri Jan 08 15:59:47 -0800 2010 | |
| |
test/ | Sun Jan 17 10:41:47 -0800 2010 |
README.md
ntest
A little test framework I wrote to get a handle on this whole asynchronous javascript thing. I don't really know what I'm doing here, other than trying to mold javascript to fit my tiny ruby brain.
Installation
There's no packaging system for node.js yet, so I've just been creating symlinks
in my ~/.node_libraries path.
$ ln -s /path/to/ntest/lib ~/.node_libraries/ntest
Usage
Mix the library into GLOBAL and start defining tests. Use whatever asserts library you like.
process.mixin(GLOBAL, require('ntest'));
var assert = require('assert') # comes with node.js
describe("an empty array")
it("has zero length", function() {
assert.equal(0, [].length);
})
Influences
Ryan Tomayko's test lib for bert:
http://github.com/rtomayko/node-bertrpc/blob/master/test/test.js
Dan Webb and FreeRange's nodetest:
http://github.com/freerange/nodetest/blob/master/nodetest.js
Copyright
Copyright (c) 2010 rick. See LICENSE for details.
