Added tests to complete pull request.

Also updated src/to.coffee to fix a header row issue in the object
output.