Class: FakeSmith::Logger

Inherits:
Object
  • Object
show all
Defined in:
lib/fake_smith.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeLogger

Returns a new instance of Logger.



106
107
108
# File 'lib/fake_smith.rb', line 106

def initialize
  @logs = {}
end

Instance Attribute Details

#logsObject (readonly)

Returns the value of attribute logs.



104
105
106
# File 'lib/fake_smith.rb', line 104

def logs
  @logs
end

Instance Method Details

#log(level) ⇒ Object



110
111
112
# File 'lib/fake_smith.rb', line 110

def log(level)
  @logs[level] ||= []
end