mirror of
https://github.com/niusmallnan/steve.git
synced 2025-08-29 18:13:56 +00:00
commit
53fbb87f59
2
go.mod
2
go.mod
@ -18,7 +18,7 @@ require (
|
||||
github.com/pborman/uuid v1.2.0
|
||||
github.com/pkg/errors v0.9.1
|
||||
github.com/prometheus/client_golang v1.12.1
|
||||
github.com/rancher/apiserver v0.0.0-20221229135954-26bed53611c4
|
||||
github.com/rancher/apiserver v0.0.0-20230120214941-e88c32739dc7
|
||||
github.com/rancher/dynamiclistener v0.3.5
|
||||
github.com/rancher/kubernetes-provider-detector v0.1.2
|
||||
github.com/rancher/norman v0.0.0-20221205184727-32ef2e185b99
|
||||
|
4
go.sum
4
go.sum
@ -502,8 +502,8 @@ github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1
|
||||
github.com/prometheus/procfs v0.7.3 h1:4jVXhlkAyzOScmCkXBTOLRLTz8EeU+eyjrwB/EPq0VU=
|
||||
github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA=
|
||||
github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU=
|
||||
github.com/rancher/apiserver v0.0.0-20221229135954-26bed53611c4 h1:eOq/tiwMCzcwexrbUQ9Agd9PHhwwtH9/G4usE0MoN8s=
|
||||
github.com/rancher/apiserver v0.0.0-20221229135954-26bed53611c4/go.mod h1:xwQhXv3XFxWfA6tLa4ZeaERu8ldNbyKv2sF+mT+c5WA=
|
||||
github.com/rancher/apiserver v0.0.0-20230120214941-e88c32739dc7 h1:Ob72oeF0iM8gWEMh+qKT5e1pzTwQU70I5kx4gMaqCmI=
|
||||
github.com/rancher/apiserver v0.0.0-20230120214941-e88c32739dc7/go.mod h1:xwQhXv3XFxWfA6tLa4ZeaERu8ldNbyKv2sF+mT+c5WA=
|
||||
github.com/rancher/client-go v1.25.4-rancher1 h1:9MlBC8QbgngUkhNzMR8rZmmCIj6WNRHFOnYiwC2Kty4=
|
||||
github.com/rancher/client-go v1.25.4-rancher1/go.mod h1:8trHCAC83XKY0wsBIpbirZU4NTUpbuhc2JnI7OruGZw=
|
||||
github.com/rancher/dynamiclistener v0.3.5 h1:5TaIHvkDGmZKvc96Huur16zfTKOiLhDtK4S+WV0JA6A=
|
||||
|
@ -64,7 +64,7 @@ func Test_countsBuffer(t *testing.T) {
|
||||
}
|
||||
|
||||
// due to complexities of cycle calculation, give a slight delay for the event to actually stream
|
||||
output, err := receiveWithTimeout(outputChannel, debounceDuration+time.Millisecond*1)
|
||||
output, err := receiveWithTimeout(outputChannel, debounceDuration+time.Millisecond*10)
|
||||
assert.NoError(t, err, "did not expect an error when receiving value from channel")
|
||||
outputCount := output.Object.Object.(Count)
|
||||
assert.Len(t, outputCount.Counts, test.numInputEvents)
|
||||
@ -93,7 +93,7 @@ func receiveWithTimeout(input chan types.APIEvent, duration time.Duration) (*typ
|
||||
case value := <-input:
|
||||
return &value, nil
|
||||
case <-time.After(duration):
|
||||
return nil, fmt.Errorf("timeout error, no value recieved after %f seconds", duration.Seconds())
|
||||
return nil, fmt.Errorf("timeout error, no value received after %f seconds", duration.Seconds())
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -177,7 +177,7 @@ func receiveWithTimeout(input chan types.APIEvent, duration time.Duration) (*typ
|
||||
case value := <-input:
|
||||
return &value, nil
|
||||
case <-time.After(duration):
|
||||
return nil, fmt.Errorf("timeout error, no value recieved after %f seconds", duration.Seconds())
|
||||
return nil, fmt.Errorf("timeout error, no value received after %f seconds", duration.Seconds())
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user