Fix tests to set missing arg

This commit is contained in:
Tim Hockin 2022-02-06 16:28:34 -08:00
parent 2a7f7f543b
commit b752a5eedc
2 changed files with 4 additions and 4 deletions

View File

@ -27,7 +27,7 @@ import (
func TestNotZeroReturnExechookDo(t *testing.T) {
t.Run("test not zero return code", func(t *testing.T) {
l := logging.New("", "")
l := logging.New("", "", 0)
ch := NewExechook(
cmd.NewRunner(l),
"false",
@ -45,7 +45,7 @@ func TestNotZeroReturnExechookDo(t *testing.T) {
func TestZeroReturnExechookDo(t *testing.T) {
t.Run("test zero return code", func(t *testing.T) {
l := logging.New("", "")
l := logging.New("", "", 0)
ch := NewExechook(
cmd.NewRunner(l),
"true",
@ -63,7 +63,7 @@ func TestZeroReturnExechookDo(t *testing.T) {
func TestTimeoutExechookDo(t *testing.T) {
t.Run("test timeout", func(t *testing.T) {
l := logging.New("", "")
l := logging.New("", "", 0)
ch := NewExechook(
cmd.NewRunner(l),
"/bin/sh",

View File

@ -31,7 +31,7 @@ func TestWebhookDo(t *testing.T) {
"POST",
200,
time.Second,
logging.New("", ""),
logging.New("", "", 0),
)
err := wh.Do(context.Background(), "hash")
if err == nil {