CrossEye/ramda — pull request #361 by kedashoe (2014-09-09 04:24:27+00:00)
Title: mocha test to compile and run ramda.js examples

Alright, here is my Frankenstein imperative/functional mocha test for the examples. There was really no hope I could write anything properly functional in a couple days so I just got what I had written to pass the lint checker and here it is.

Basic idea:

- parse the function comments (and function declarations for mocha it() descriptions)
- extract example, parse example so we can test the //=> 'eg' as assertions
- inject our executable example source as a function in ramda (so that we can also run internal function examples)
- run our example function, see what happens

If you want to see all the assertions being run, you can just add `console.log(msg);` to `assertPairEqual` (maybe grunt option for more verbose?)