Removed the coffeescript and simplified the tests. Will investigate a
good way of testing correctness for this.