discourse/spec/support/fake_logger.rb
Kyle Zhao e9a971a2b6
FEATURE: [Experimental] Content Security Policy (#6514)
do not register new MIME type, parse raw body instead
2018-10-22 13:22:23 -04:00

22 lines
296 B
Ruby

class FakeLogger
attr_reader :warnings, :errors, :infos
def initialize
@warnings = []
@errors = []
@infos = []
end
def info(message = nil)
@infos << message
end
def warn(message)
@warnings << message
end
def error(message)
@errors << message
end
end