Skip to content
This repository was archived by the owner on Nov 18, 2026. It is now read-only.

Commit aa731fc

Browse files
committed
Fix render tests now missingkey is set to zero not error.
1 parent 87a2a0b commit aa731fc

1 file changed

Lines changed: 0 additions & 11 deletions

File tree

‎template/render_test.go‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ package template
22

33
import (
44
"os"
5-
"strings"
65
"testing"
76

87
nomad "github.com/hashicorp/nomad/api"
@@ -108,14 +107,4 @@ func TestTemplater_RenderTemplate(t *testing.T) {
108107
if *job.TaskGroups[0].Name != testEnvValue {
109108
t.Fatalf("expected %s but got %v", testEnvValue, *job.TaskGroups[0].Name)
110109
}
111-
112-
// Test var-args only render.
113-
fVars["job_name"] = testJobName
114-
_, err = RenderTemplate("test-fixtures/missing_var.nomad", []string{}, "", &fVars)
115-
if err == nil {
116-
t.Fatal("expected err to not be nil")
117-
}
118-
if !strings.Contains(err.Error(), "binary_url") {
119-
t.Fatal("expected err to mention missing var (binary_url)")
120-
}
121110
}

0 commit comments

Comments
 (0)
⌂ 换网址