File tree Expand file tree Collapse file tree 3 files changed +8
-1
lines changed
internal/cli/configuration Expand file tree Collapse file tree 3 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -134,5 +134,7 @@ issues:
134134 - path-except : internal/cli/
135135 linters :
136136 - forbidigo
137+ - path : internal/cli/.*_test.go
138+ linters : [forbidigo]
137139 - path : internal/cli/feedback/
138140 linters : [forbidigo]
Original file line number Diff line number Diff line change @@ -64,6 +64,10 @@ func SetDefaults(settings *Settings) {
6464
6565 // updater settings
6666 setDefaultValueAndKeyTypeSchema ("updater.enable_notification" , true )
67+
68+ // network settings
69+ setKeyTypeSchema ("network.proxy" , "" )
70+ setKeyTypeSchema ("network.user_agent_ext" , "" )
6771}
6872
6973// InjectEnvVars change settings based on the environment variables values
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ func TestUserAgentHeader(t *testing.T) {
3333 defer ts .Close ()
3434
3535 settings := configuration .NewSettings ()
36- settings .Set ("network.user_agent_ext" , "test-user-agent" )
36+ require . NoError ( t , settings .Set ("network.user_agent_ext" , "test-user-agent" ) )
3737 client , err := settings .NewHttpClient ()
3838 require .NoError (t , err )
3939
@@ -46,6 +46,7 @@ func TestUserAgentHeader(t *testing.T) {
4646 b , err := io .ReadAll (response .Body )
4747 require .NoError (t , err )
4848
49+ fmt .Println ("RESPONSE:" , string (b ))
4950 require .Contains (t , string (b ), "test-user-agent" )
5051}
5152
You can’t perform that action at this time.
0 commit comments