|
|
|
@ -81,17 +81,17 @@ func TestCheckDefinitionToCheckType(t *testing.T) {
|
|
|
|
|
Status: "green",
|
|
|
|
|
Notes: "notes",
|
|
|
|
|
|
|
|
|
|
ServiceID: "svcid",
|
|
|
|
|
Token: "tok",
|
|
|
|
|
ScriptArgs: []string{"/bin/foo"},
|
|
|
|
|
HTTP: "someurl",
|
|
|
|
|
TCP: "host:port",
|
|
|
|
|
Interval: 1 * time.Second,
|
|
|
|
|
DockerContainerID: "abc123",
|
|
|
|
|
Shell: "/bin/ksh",
|
|
|
|
|
TLSSkipVerify: true,
|
|
|
|
|
Timeout: 2 * time.Second,
|
|
|
|
|
TTL: 3 * time.Second,
|
|
|
|
|
ServiceID: "svcid",
|
|
|
|
|
Token: "tok",
|
|
|
|
|
ScriptArgs: []string{"/bin/foo"},
|
|
|
|
|
HTTP: "someurl",
|
|
|
|
|
TCP: "host:port",
|
|
|
|
|
Interval: 1 * time.Second,
|
|
|
|
|
DockerContainerID: "abc123",
|
|
|
|
|
Shell: "/bin/ksh",
|
|
|
|
|
TLSSkipVerify: true,
|
|
|
|
|
Timeout: 2 * time.Second,
|
|
|
|
|
TTL: 3 * time.Second,
|
|
|
|
|
DeregisterCriticalServiceAfter: 4 * time.Second,
|
|
|
|
|
}
|
|
|
|
|
want := &CheckType{
|
|
|
|
@ -100,15 +100,15 @@ func TestCheckDefinitionToCheckType(t *testing.T) {
|
|
|
|
|
Status: "green",
|
|
|
|
|
Notes: "notes",
|
|
|
|
|
|
|
|
|
|
ScriptArgs: []string{"/bin/foo"},
|
|
|
|
|
HTTP: "someurl",
|
|
|
|
|
TCP: "host:port",
|
|
|
|
|
Interval: 1 * time.Second,
|
|
|
|
|
DockerContainerID: "abc123",
|
|
|
|
|
Shell: "/bin/ksh",
|
|
|
|
|
TLSSkipVerify: true,
|
|
|
|
|
Timeout: 2 * time.Second,
|
|
|
|
|
TTL: 3 * time.Second,
|
|
|
|
|
ScriptArgs: []string{"/bin/foo"},
|
|
|
|
|
HTTP: "someurl",
|
|
|
|
|
TCP: "host:port",
|
|
|
|
|
Interval: 1 * time.Second,
|
|
|
|
|
DockerContainerID: "abc123",
|
|
|
|
|
Shell: "/bin/ksh",
|
|
|
|
|
TLSSkipVerify: true,
|
|
|
|
|
Timeout: 2 * time.Second,
|
|
|
|
|
TTL: 3 * time.Second,
|
|
|
|
|
DeregisterCriticalServiceAfter: 4 * time.Second,
|
|
|
|
|
}
|
|
|
|
|
verify.Values(t, "", got.CheckType(), want)
|
|
|
|
|