test(options): increase tests coverage (#2183)

Co-authored-by: aythen <634222210@qq.com>
pull/2185/head
jakezhu9 2 years ago committed by GitHub
parent b3eff576ce
commit afd108cdc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 9
      options_test.go

@ -143,3 +143,12 @@ func TestRegistrarTimeout(t *testing.T) {
t.Fatal("o.registrarTimeout is not equal to v")
}
}
func TestStopTimeout(t *testing.T) {
o := &options{}
v := time.Duration(123)
StopTimeout(v)(o)
if !reflect.DeepEqual(v, o.stopTimeout) {
t.Fatal("o.stopTimeout is not equal to v")
}
}

Loading…
Cancel
Save