From a967986a18754810311a297dbe0d4d27da7d5e1b Mon Sep 17 00:00:00 2001 From: Christian Schwarz Date: Sun, 9 Oct 2022 15:28:24 +0200 Subject: [PATCH] fixup: fix hooks unit tests The previous commit c743c7b03f13fd6aae37ec226a344c0ff892f698 broke the hooks unit tests. GitHub was not configured to require passing tests for master merge. Didn't notice it locally due to Go's test caching. I amended this before pushing this change. --- daemon/hooks/hooks_test.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/daemon/hooks/hooks_test.go b/daemon/hooks/hooks_test.go index d498e08..5e23d4d 100644 --- a/daemon/hooks/hooks_test.go +++ b/daemon/hooks/hooks_test.go @@ -161,7 +161,7 @@ jobs: ExpectedEdge: hooks.Pre, ExpectStatus: hooks.StepErr, OutputTest: containsTest(fmt.Sprintf("TEST ERROR pre_testing %s@%s", testFSName, testSnapshotName)), - ErrorTest: regexpTest("^command hook invocation.*exit status 1$"), + ErrorTest: regexpTest("^command hook failed.*exit status 1$"), }, expectStep{ExpectedEdge: hooks.Callback, ExpectStatus: hooks.StepOk}, expectStep{ @@ -185,7 +185,7 @@ jobs: ExpectedEdge: hooks.Pre, ExpectStatus: hooks.StepErr, OutputTest: containsTest(fmt.Sprintf("TEST ERROR pre_testing %s@%s", testFSName, testSnapshotName)), - ErrorTest: regexpTest("^command hook invocation.*exit status 1$"), + ErrorTest: regexpTest("^command hook failed.*exit status 1$"), }, expectStep{ ExpectedEdge: hooks.Pre, @@ -234,7 +234,7 @@ jobs: ExpectedEdge: hooks.Post, ExpectStatus: hooks.StepErr, OutputTest: containsTest(fmt.Sprintf("TEST ERROR post_testing %s@%s", testFSName, testSnapshotName)), - ErrorTest: regexpTest("^command hook invocation.*exit status 1$"), + ErrorTest: regexpTest("^command hook failed.*exit status 1$"), }, }, }, @@ -267,7 +267,7 @@ jobs: ExpectedEdge: hooks.Pre, ExpectStatus: hooks.StepErr, OutputTest: containsTest(fmt.Sprintf("TEST ERROR pre_testing %s@%s", testFSName, testSnapshotName)), - ErrorTest: regexpTest("^command hook invocation.*exit status 1$"), + ErrorTest: regexpTest("^command hook failed.*exit status 1$"), }, expectStep{ExpectedEdge: hooks.Callback, ExpectStatus: hooks.StepOk}, expectStep{ @@ -295,7 +295,7 @@ jobs: ExpectedEdge: hooks.Pre, ExpectStatus: hooks.StepErr, OutputTest: containsTest(fmt.Sprintf("TEST ERROR pre_testing %s@%s", testFSName, testSnapshotName)), - ErrorTest: regexpTest("^command hook invocation.*exit status 1$"), + ErrorTest: regexpTest("^command hook failed.*exit status 1$"), }, expectStep{ExpectedEdge: hooks.Callback, ExpectStatus: hooks.StepOk}, expectStep{