mirror of
https://github.com/mikefarah/yq.git
synced 2026-07-10 16:55:40 +00:00
add two test cases, have source uses ascii only
This commit is contained in:
parent
053ba7304a
commit
55a8205397
@ -61,7 +61,7 @@ func TestShellVariablesEncoderKeyPrintableNonAlphaNumeric(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestShellVariablesEncoderKeyPrintableNonAscii(t *testing.T) {
|
||||
assertEncodesTo(t, `"bèll": ring!`, "bell='ring!'")
|
||||
assertEncodesTo(t, `"b\u00e9ll": ring!`, "bell='ring!'")
|
||||
}
|
||||
|
||||
func TestShellVariablesEncoderRootKeyStartingWithDigit(t *testing.T) {
|
||||
@ -72,6 +72,14 @@ func TestShellVariablesEncoderEmptyValue(t *testing.T) {
|
||||
assertEncodesTo(t, "empty:", "empty=")
|
||||
}
|
||||
|
||||
func TestShellVariablesEncoderEmptyArray(t *testing.T) {
|
||||
assertEncodesTo(t, "empty: []", "")
|
||||
}
|
||||
|
||||
func TestShellVariablesEncoderEmptyMap(t *testing.T) {
|
||||
assertEncodesTo(t, "empty: {}", "")
|
||||
}
|
||||
|
||||
func TestShellVariablesEncoderScalarNode(t *testing.T) {
|
||||
assertEncodesTo(t, "some string", "value='some string'")
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user