Skip to content

Commit

Permalink
test: revert error suppresion (#2363)
Browse files Browse the repository at this point in the history
Signed-off-by: Matej Vašek <[email protected]>
  • Loading branch information
matejvasek authored Jun 14, 2024
1 parent 6bb9a3e commit f72b666
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 29 deletions.
11 changes: 1 addition & 10 deletions test/e2e/scenario_runtime-cloudevents_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import (
"path/filepath"
"strings"
"testing"
"time"

"gotest.tools/v3/assert"
"knative.dev/func/test/testhttp"
Expand Down Expand Up @@ -36,15 +35,7 @@ func lifecycleCloudEventsTest(t *testing.T, language string, builder string) {

knFunc.Exec("create", "--language", language, "--template", "cloudevents", funcPath)
knFunc.Exec("deploy", "--registry", common.GetRegistry(), "--builder", builder, "--path", funcPath)

defer func() {
// temporarily ignore deletion error because Node has broken signal handling
// TODO fix this
if builder == "s2i" && (language == "node" || language == "typescript") && time.Now().Before(time.Date(2024, 5, 31, 0, 0, 0, 0, time.UTC)) {
knFunc.ShouldFailOnError = false
}
knFunc.Exec("delete", "--path", funcPath)
}()
defer knFunc.Exec("delete", "--path", funcPath)

_, functionUrl := common.WaitForFunctionReady(t, funcName)

Expand Down
11 changes: 1 addition & 10 deletions test/e2e/scenario_runtime-http_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"path/filepath"
"strings"
"testing"
"time"

"gotest.tools/v3/assert"
"knative.dev/func/test/testhttp"
Expand Down Expand Up @@ -76,15 +75,7 @@ func lifecycleHttpTest(t *testing.T, language string, builder string) {

knFunc.Exec("create", "--language", language, "--template", "http", funcPath)
knFunc.Exec("deploy", "--registry", common.GetRegistry(), "--builder", builder, "--path", funcPath)

defer func() {
// temporarily ignore deletion error because Node has broken signal handling
// TODO fix this
if builder == "s2i" && (language == "node" || language == "typescript") && time.Now().Before(time.Date(2024, 5, 31, 0, 0, 0, 0, time.UTC)) {
knFunc.ShouldFailOnError = false
}
knFunc.Exec("delete", "--path", funcPath)
}()
defer knFunc.Exec("delete", "--path", funcPath)

_, functionUrl := common.WaitForFunctionReady(t, funcName)

Expand Down
10 changes: 1 addition & 9 deletions test/oncluster/scenario_runtime_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"path/filepath"
"strings"
"testing"
"time"

"k8s.io/apimachinery/pkg/util/rand"
common "knative.dev/func/test/common"
Expand Down Expand Up @@ -82,14 +81,7 @@ func runtimeImpl(t *testing.T, lang string, builder string) {
"--builder", builder,
"--git-url", remoteRepo.ClusterCloneURL)

defer func() {
// temporarily ignore deletion error because Node has broken signal handling
// TODO fix this
if builder == "s2i" && (lang == "node" || lang == "typescript") && time.Now().Before(time.Date(2024, 5, 31, 0, 0, 0, 0, time.UTC)) {
knFunc.ShouldFailOnError = false
}
knFunc.Exec("delete", "-p", funcPath)
}()
defer knFunc.Exec("delete", "-p", funcPath)

// -- Assertions --
result := knFunc.Exec("invoke", "-p", funcPath)
Expand Down

0 comments on commit f72b666

Please sign in to comment.