Skip to content

Commit

Permalink
Add unset values in TestFillConfigWithFlagsValidVals
Browse files Browse the repository at this point in the history
  • Loading branch information
bbrks committed Jun 5, 2024
1 parent 0b5307f commit d799c7a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions rest/config_flags_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,12 @@ func TestFillConfigWithFlagsValidVals(t *testing.T) {
assert.Equal(t, "warn", config.Logging.Console.LogLevel.String())
assert.Equal(t, base.NewConfigDuration(time.Hour*5+time.Minute*2+time.Second*33), config.Replicator.MaxHeartbeat)
assert.Equal(t, uint64(12345), config.MaxFileDescriptors)

// unset values
assert.Equal(t, "", config.Bootstrap.X509CertPath) // String
assert.Nil(t, config.API.CORS.Headers) // []string
assert.Nil(t, config.API.AdminInterfaceAuthentication) // *bool
assert.Nil(t, config.Logging.Warn.Rotation.RotationInterval) // *base.ConfigDuration
}

// Manually test different types of flags with invalid values
Expand Down

0 comments on commit d799c7a

Please sign in to comment.