@@ -116,6 +116,7 @@ func TestConfig_override_defaults_with_env_vars(t *testing.T) {
116116	usingEnvVar (t , "GZIP_COMPRESSION_ENABLED" , "0" )
117117	usingEnvVar (t , "DEBUG" , "1" )
118118	usingEnvVar (t , "ACME_DIRECTORY" , "https://acme-staging-v02.api.letsencrypt.org/directory" )
119+ 	usingEnvVar (t , "LOG_REQUESTS" , "false" )
119120
120121	c , err  :=  NewConfig ()
121122	require .NoError (t , err )
@@ -127,6 +128,7 @@ func TestConfig_override_defaults_with_env_vars(t *testing.T) {
127128	assert .Equal (t , false , c .GzipCompressionEnabled )
128129	assert .Equal (t , slog .LevelDebug , c .LogLevel )
129130	assert .Equal (t , "https://acme-staging-v02.api.letsencrypt.org/directory" , c .ACMEDirectoryURL )
131+ 	assert .Equal (t , false , c .LogRequests )
130132}
131133
132134func  TestConfig_override_defaults_with_env_vars_using_prefix (t  * testing.T ) {
@@ -136,6 +138,7 @@ func TestConfig_override_defaults_with_env_vars_using_prefix(t *testing.T) {
136138	usingEnvVar (t , "THRUSTER_HTTP_READ_TIMEOUT" , "5" )
137139	usingEnvVar (t , "THRUSTER_X_SENDFILE_ENABLED" , "0" )
138140	usingEnvVar (t , "THRUSTER_DEBUG" , "1" )
141+ 	usingEnvVar (t , "THRUSTER_LOG_REQUESTS" , "0" )
139142
140143	c , err  :=  NewConfig ()
141144	require .NoError (t , err )
@@ -145,6 +148,7 @@ func TestConfig_override_defaults_with_env_vars_using_prefix(t *testing.T) {
145148	assert .Equal (t , 5 * time .Second , c .HttpReadTimeout )
146149	assert .Equal (t , false , c .XSendfileEnabled )
147150	assert .Equal (t , slog .LevelDebug , c .LogLevel )
151+ 	assert .Equal (t , false , c .LogRequests )
148152}
149153
150154func  TestConfig_prefixed_variables_take_precedence_over_non_prefixed (t  * testing.T ) {
0 commit comments