Loggability::
SpecHelpers module
Some helper functions for testing. Usage:
# in spec_helpers.rb RSpec.configure do |c| c.include( Loggability::SpecHelpers ) end # in my_class_spec.rb; set logging level to :error describe MyClass, log: :error do # Except for this example, which logs at :debug it "does something", log: :debug do # anything the spec does here will be logged at :debug end it "does something else" do # but this will use the :error level from the 'describe' end end
Public Class Methods
Inclusion callback – install some hooks that set up logging for RSpec specs.
Public Instance Methods
Reset the logging subsystem to its default state.
Alter the output of the default log formatter to be pretty in SpecMate output if HTML_LOGGING is set or TM_FILENAME is set to something containing _spec.rb.