lib/td/logger/agent/rails/config.rb in td-logger-0.3.19 vs lib/td/logger/agent/rails/config.rb in td-logger-0.3.20
- old
+ new
@@ -28,23 +28,28 @@
end
@debug_mode = !!conf['debug_mode']
end
+ @test_mode = !!conf['test_mode']
@access_log_table = conf['access_log_table']
end
attr_reader :agent_host, :agent_port, :tag
attr_reader :apikey, :database, :auto_create_table
- attr_reader :access_log_table, :debug_mode
+ attr_reader :access_log_table, :debug_mode, :test_mode
attr_accessor :disabled
def initialize
@disabled = false
end
def agent_mode?
@agent_host != nil
+ end
+
+ def test_mode?
+ @test_mode
end
def access_log_enabled?
!@access_log_table.nil? && !@access_log_table.empty?
end