diff options
| author | Dave Henderson <dhenderson@gmail.com> | 2017-06-04 16:04:36 -0400 |
|---|---|---|
| committer | Dave Henderson <dhenderson@gmail.com> | 2017-06-05 10:20:44 -0400 |
| commit | b1730c1956aed244d9d05255c95f427fdfcf4d1e (patch) | |
| tree | 19257a9e4ef7fec51177f4a7e36fced7a85055fc /test | |
| parent | a4ddbc506abd34da600abb392513a1e49ea04548 (diff) | |
Adding TOML support
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
Diffstat (limited to 'test')
| -rw-r--r-- | test/integration/typeconv_funcs.bats | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/integration/typeconv_funcs.bats b/test/integration/typeconv_funcs.bats index 46c735cc..0b22f311 100644 --- a/test/integration/typeconv_funcs.bats +++ b/test/integration/typeconv_funcs.bats @@ -89,3 +89,22 @@ Languages are: {{ join $c.lang " and " }}' [ "$status" -eq 0 ] [[ "${output}" == "Languages are: C and Go and COBOL" ]] } + +@test "'toml'" { + gomplate -i '{{ $t := `# comment +foo = "bar" + +[baz] +qux = "quux"` | toml -}} +{{ $t.baz.qux }}' + [ "$status" -eq 0 ] + [[ "${output}" == "quux" ]] +} + +@test "'toTOML'" { + gomplate -i '{{ "foo:\n bar:\n baz: qux" | yaml | toTOML }}' + [ "$status" -eq 0 ] + [[ "${output}" == "[foo] + [foo.bar] + baz = \"qux\"" ]] +}
\ No newline at end of file |
