Commit 810d5e8d authored by Gabriel Mazetto's avatar Gabriel Mazetto Committed by Nick Thomas

Geo Logger should use the same log level defined in Rails

parent 4e6a9f1d
---
title: Geo Logger will use the same log level defined in Rails
merge_request: 4066
author:
type: changed
......@@ -4,6 +4,10 @@ module Gitlab
def self.file_name_noext
'geo'
end
def self.build
super.tap { |logger| logger.level = Rails.logger.level }
end
end
end
end
require 'spec_helper'
describe Gitlab::Geo::Logger do
it 'uses the same log_level defined in Rails' do
allow(Rails.logger).to receive(:level) { 99 }
expect_any_instance_of(::Gitlab::Geo::Logger).to receive(:level=).with(99)
described_class.build
end
end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment