Sonar complience

Use valid names and factorize some constants checks
This commit is contained in:
2024-10-18 09:34:57 +02:00
parent d2c8d08b7f
commit 533e1422d0
8 changed files with 37 additions and 36 deletions

View File

@@ -1,12 +1,11 @@
package generator
import (
"katenary/parser"
"log"
"os"
"os/exec"
"testing"
"katenary/parser"
)
const unmarshalError = "Failed to unmarshal the output: %s"
@@ -29,8 +28,8 @@ func teardown(tmpDir string) {
}
}
func _compile_test(t *testing.T, options ...string) string {
_, err := parser.Parse(nil, "compose.yml")
func internalCompileTest(t *testing.T, options ...string) string {
_, err := parser.Parse(nil, nil, "compose.yml")
if err != nil {
t.Fatalf("Failed to parse the project: %s", err)
}