Skip to content

Commit

Permalink
Add custom formatter for jasmine to print each executed test
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperTux88 authored and Flaburgan committed Jul 17, 2022
1 parent a517e66 commit e3a4422
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions spec/javascripts/support/jasmine_helper.rb
@@ -1,5 +1,17 @@
# frozen_string_literal: true

class NameFormatter
def format(results)
results.each do |result|
puts "#{result.full_name}: #{result.send(:status)}"
end
end

def done(result)
puts "Done running tests: #{result}"
end
end

Jasmine.configure do |config|
config.prevent_phantom_js_auto_install = true
config.runner_browser = :chromeheadless
Expand All @@ -8,4 +20,5 @@
config.chrome_cli_options["disable-gpu"] = nil
config.chrome_cli_options["disable-software-rasterizer"] = nil
config.chrome_cli_options["disable-dev-shm-usage"] = nil
config.formatters << NameFormatter
end

0 comments on commit e3a4422

Please sign in to comment.