summaryrefslogtreecommitdiffstats
path: root/parser/frontmatter_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'parser/frontmatter_test.go')
-rw-r--r--parser/frontmatter_test.go16
1 files changed, 8 insertions, 8 deletions
diff --git a/parser/frontmatter_test.go b/parser/frontmatter_test.go
index dfbc695d8..7b3ffc100 100644
--- a/parser/frontmatter_test.go
+++ b/parser/frontmatter_test.go
@@ -23,33 +23,33 @@ import (
func TestInterfaceToConfig(t *testing.T) {
cases := []struct {
- input interface{}
+ input any
format metadecoders.Format
want []byte
isErr bool
}{
// TOML
- {map[string]interface{}{}, metadecoders.TOML, nil, false},
+ {map[string]any{}, metadecoders.TOML, nil, false},
{
- map[string]interface{}{"title": "test' 1"},
+ map[string]any{"title": "test' 1"},
metadecoders.TOML,
[]byte("title = \"test' 1\"\n"),
false,
},
// YAML
- {map[string]interface{}{}, metadecoders.YAML, []byte("{}\n"), false},
+ {map[string]any{}, metadecoders.YAML, []byte("{}\n"), false},
{
- map[string]interface{}{"title": "test 1"},
+ map[string]any{"title": "test 1"},
metadecoders.YAML,
[]byte("title: test 1\n"),
false,
},
// JSON
- {map[string]interface{}{}, metadecoders.JSON, []byte("{}\n"), false},
+ {map[string]any{}, metadecoders.JSON, []byte("{}\n"), false},
{
- map[string]interface{}{"title": "test 1"},
+ map[string]any{"title": "test 1"},
metadecoders.JSON,
[]byte("{\n \"title\": \"test 1\"\n}\n"),
false,
@@ -57,7 +57,7 @@ func TestInterfaceToConfig(t *testing.T) {
// Errors
{nil, metadecoders.TOML, nil, true},
- {map[string]interface{}{}, "foo", nil, true},
+ {map[string]any{}, "foo", nil, true},
}
for i, c := range cases {