Simple phantom script to run jasmine tests.
This is a phantom script that is derived from the jasmine example on phantomjs site. There were bugs in it so I re-wrote the example to work with Jasmine 2.0.0.
Download the script, and throw run-jasmine.js into the directory that runs your SpecRunner.html file. You can actually place it anywhere you want and use a relative path name. You still need SpecRunner.html to work. Such a file will look similar to what is bellow:
Once you have your SpecRunner.html setup, simply run it with phantomjs using the following command:
phantomjs run-jasmine.js SpecRunner.html
On a side note, you don't have to name you file SpecRunner.html. It can be called anything you want such as testFile.html.
phantomjs run-jasmine.js testFile.html
phantomjs run-jasmine.js path/to/RandomSpecRunningFile.html
phantomjs run-jasmine.js [relative path to file]