class method
self.plugin_rails_init
Ruby on Rails 5.0.7.2
Since v5.0.7.2Signature
self.plugin_rails_init(options)
Owes great inspiration to test runner trailblazers like RSpec, minitest-reporters, maxitest and others.
Parameters
-
optionsreq
Source
# File railties/lib/minitest/rails_plugin.rb, line 35
def self.plugin_rails_init(options)
unless options[:full_backtrace] || ENV["BACKTRACE"]
# Plugin can run without Rails loaded, check before filtering.
Minitest.backtrace_filter = ::Rails.backtrace_cleaner if ::Rails.respond_to?(:backtrace_cleaner)
end
# Replace progress reporter for colors.
reporter.reporters.delete_if { |reporter| reporter.kind_of?(SummaryReporter) || reporter.kind_of?(ProgressReporter) }
reporter << SuppressedSummaryReporter.new(options[:io], options)
reporter << ::Rails::TestUnitReporter.new(options[:io], options)
end
Defined in railties/lib/minitest/rails_plugin.rb line 35
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in Minitest