Skip to content

Commit

Permalink
add a no prefix test
Browse files Browse the repository at this point in the history
  • Loading branch information
ldemailly committed Nov 21, 2023
1 parent 9837240 commit 8cb1f75
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions env_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,12 @@ TST_TS='1998-11-05T14:30:00Z'
if str != expected {
t.Errorf("\n---expected:---\n%s\n---got:---\n%s", expected, str)
}
// Same no prefix
str = ToShell(envVars)
expected = strings.ReplaceAll(expected, "TST_", "")
if str != expected {
t.Errorf("\n---expected:---\n%s\n---got:---\n%s", expected, str)
}
// YAML check
str = ToYamlWithPrefix(2, "Y_", envVars)
expected = ` - name: Y_FOO
Expand Down

0 comments on commit 8cb1f75

Please sign in to comment.