Created
January 19, 2014 23:21
-
-
Save fonzerelly/8512357 to your computer and use it in GitHub Desktop.
Rhino based SpecRunner for jasmine
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Imported by Rhino on command shell | |
/*global load, print*/ | |
load("lib/Timer.js"); | |
/*global endAllTimers*/ | |
load("lib/TextReporter.js"); | |
/*global TextReporter*/ | |
load("lib/jasmine-1.3.0/jasmine.js"); | |
/*global jasmine*/ | |
Array.prototype.splice.call(arguments).forEach( function (spec) { | |
load(spec); | |
}); | |
var jasmineEnv = jasmine.getEnv(); | |
jasmineEnv.updateInterval = 1000; | |
var txtReporter = new TextReporter(); | |
txtReporter.onRunnerFinished(function (text) { | |
// Do something with text // | |
print (text); | |
endAllTimers(); | |
}); | |
jasmineEnv.addReporter(txtReporter); | |
jasmine.getEnv().execute(); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment