Build and run on Node v0.10.x

I've only tested this with 0.10.4 (on Mountain Lion), but the changes are based on https://github.com/joyent/node/wiki/Api-changes-between-v0.8-and-v0.10 and they're pretty straight forward.

Also added support for using `npm test` to run the tests.

Fixes #5