Skip to content

Commit e95c1cf

Browse files
srebhanglours
andcommitted
Update template/template_test.go
Signed-off-by: Sven Rebhan <[email protected]> Co-authored-by: Guillaume Lours <[email protected]>
1 parent 6776bc9 commit e95c1cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

template/template_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ func TestSubstituteWithReplacementFunc(t *testing.T) {
381381
options := []Option{
382382
WithReplacementFunction(func(s string, m Mapping, c *Config) (string, error) {
383383
if s == "${NOTHERE}" {
384-
return "", fmt.Errorf("bad choice dude: %q", s)
384+
return "", fmt.Errorf("bad choice: %q", s)
385385
}
386386
r, err := DefaultReplacementFunc(s, m, c)
387387
if err == nil && r != "" {
@@ -399,7 +399,7 @@ func TestSubstituteWithReplacementFunc(t *testing.T) {
399399
assert.Check(t, is.Equal("ok foobar", result))
400400

401401
_, err = SubstituteWithOptions("ok ${NOTHERE}", defaultMapping, options...)
402-
assert.Check(t, is.ErrorContains(err, "bad choice dude"))
402+
assert.Check(t, is.ErrorContains(err, "bad choice"))
403403
}
404404

405405
// TestPrecedence tests is the precedence on '-' and '?' is of the first match

0 commit comments

Comments
 (0)