From b5f62d43afbaaa6d7495b3e71da109f11f8b9bf7 Mon Sep 17 00:00:00 2001 From: Patrice Ferlet Date: Wed, 4 Jun 2025 09:46:13 +0200 Subject: [PATCH] fix(test): Fix non constant string format Go 1.24 made several changes about formatting messages: https://tip.golang.org/doc/go1.24#vet These changes make tests (and vet) craching. The fix is to use a string format and give error message as argument. --- generator/katenaryfile/main_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/generator/katenaryfile/main_test.go b/generator/katenaryfile/main_test.go index 12c4997..559f322 100644 --- a/generator/katenaryfile/main_test.go +++ b/generator/katenaryfile/main_test.go @@ -33,7 +33,7 @@ webapp: // create /tmp/katenary-test-override directory, save the compose.yaml file tmpDir, err := os.MkdirTemp("", "katenary-test-override") if err != nil { - t.Fatalf(err.Error()) + t.Fatalf("Failed to create temp directory: %s", err.Error()) } composeFile := filepath.Join(tmpDir, "compose.yaml") katenaryFile := filepath.Join(tmpDir, "katenary.yaml") @@ -83,7 +83,7 @@ webapp: // create /tmp/katenary-test-override directory, save the compose.yaml file tmpDir, err := os.MkdirTemp("", "katenary-test-override") if err != nil { - t.Fatalf(err.Error()) + t.Fatalf("Failed to create temp directory: %s", err.Error()) } composeFile := filepath.Join(tmpDir, "compose.yaml") katenaryFile := filepath.Join(tmpDir, "katenary.yaml")