Monday, January 13, 2014

Jasmine parameterized test

https://gist.github.com/basti1302/5051200

I built a jasmine test to test the output of a single command (my logax command).  Then I wanted to test various input file formats with the same exact test code.  I like to keep it DRY, so I created a parameterized jasmine test.  The example above in github is for coffeescript, but it can easily be adapted to javascript.

Here's my JavaScript version: 

https://gist.github.com/jesslilly/8418545