diff --git a/skel/template.html.erb b/skel/template.html.erb index 05f7038..4da2057 100644 --- a/skel/template.html.erb +++ b/skel/template.html.erb @@ -23,7 +23,15 @@ if (window.JHW) { jasmine.getEnv().addReporter(new jasmine.HeadlessConsoleReporter()); } else { - jasmine.getEnv().addReporter(new jasmine.HtmlReporter()); + types = [ 'HtmlReporter', 'TrivialReporter' ]; + + for (var i = 0, j = types.length; i < j; ++i) { + var type = jasmine[types[i]] + if (type) { + jasmine.getEnv().addReporter(new type()); + break; + } + } } jasmine.getEnv().execute(); diff --git a/vendor/assets/coffeescripts/headless_reporter_result.coffee b/vendor/assets/coffeescripts/headless_reporter_result.coffee index 077b571..0c8e752 100644 --- a/vendor/assets/coffeescripts/headless_reporter_result.coffee +++ b/vendor/assets/coffeescripts/headless_reporter_result.coffee @@ -11,7 +11,7 @@ class window.HeadlessReporterResult bestChoice = HeadlessReporterResult.findSpecLine(@splitName) output += " (#{bestChoice.file}:#{bestChoice.lineNumber})".foreground('blue') if bestChoice.file - JHW.stdout.puts "\n\n#{output}" + JHW.stdout.puts "\n#{output}" for result in @results output = result.message.foreground('red') if result.lineNumber diff --git a/vendor/assets/javascripts/headless_reporter_result.js b/vendor/assets/javascripts/headless_reporter_result.js index 14ba347..5498284 100644 --- a/vendor/assets/javascripts/headless_reporter_result.js +++ b/vendor/assets/javascripts/headless_reporter_result.js @@ -15,7 +15,7 @@ if (bestChoice.file) { output += (" (" + bestChoice.file + ":" + bestChoice.lineNumber + ")").foreground('blue'); } - JHW.stdout.puts("\n\n" + output); + JHW.stdout.puts("\n" + output); _ref = this.results; _results = []; for (_i = 0, _len = _ref.length; _i < _len; _i++) {