1
0
Fork 0
mirror of https://github.com/puma/puma.git synced 2022-11-09 13:48:40 -05:00

Remove unused file_log_requests_config variable (#2140)

Also add extra test to show the default log_request config when no file
is present.
This commit is contained in:
Nate Berkopec 2020-03-05 11:21:01 -06:00 committed by GitHub
parent 9b5137a5d1
commit 4184180c71
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -227,6 +227,13 @@ class TestUserSuppliedOptionsIsNotPresent < Minitest::Test
end
end
def test_default_log_request_when_no_config_file
conf = Rack::Handler::Puma.config(->{}, @options)
conf.load
assert_equal false, conf.options[:log_requests]
end
def test_file_log_requests_wins_over_default_config
file_log_requests_config = true
@ -240,9 +247,7 @@ class TestUserSuppliedOptionsIsNotPresent < Minitest::Test
assert_equal file_log_requests_config, conf.options[:log_requests]
end
def test_user_log_requests_wins_over_file_config
file_log_requests_config = true
user_log_requests_config = false
@options[:log_requests] = user_log_requests_config