Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'hugolib/content_map_test.go')
-rw-r--r--hugolib/content_map_test.go16
1 files changed, 8 insertions, 8 deletions
diff --git a/hugolib/content_map_test.go b/hugolib/content_map_test.go
index a62380efd..014ef9c7d 100644
--- a/hugolib/content_map_test.go
+++ b/hugolib/content_map_test.go
@@ -51,9 +51,9 @@ func BenchmarkContentMap(b *testing.B) {
meta := fi.Meta()
// We have a more elaborate filesystem setup in the
// real flow, so simulate this here.
- meta["lang"] = lang
- meta["path"] = meta.Filename()
- meta["classifier"] = files.ClassifyContentFile(fi.Name(), meta.GetOpener())
+ meta.Lang = lang
+ meta.Path = meta.Filename
+ meta.Classifier = files.ClassifyContentFile(fi.Name(), meta.OpenFunc)
})
}
@@ -109,10 +109,10 @@ func TestContentMap(t *testing.T) {
meta := fi.Meta()
// We have a more elaborate filesystem setup in the
// real flow, so simulate this here.
- meta["lang"] = lang
- meta["path"] = meta.Filename()
- meta["classifier"] = files.ClassifyContentFile(fi.Name(), meta.GetOpener())
- meta["translationBaseName"] = paths.Filename(fi.Name())
+ meta.Lang = lang
+ meta.Path = meta.Filename
+ meta.TranslationBaseName = paths.Filename(fi.Name())
+ meta.Classifier = files.ClassifyContentFile(fi.Name(), meta.OpenFunc)
})
}
@@ -127,7 +127,7 @@ func TestContentMap(t *testing.T) {
header := writeFile(c, fs, "blog/a/index.md", "page")
- c.Assert(header.Meta().Lang(), qt.Equals, "en")
+ c.Assert(header.Meta().Lang, qt.Equals, "en")
resources := []hugofs.FileMetaInfo{
writeFile(c, fs, "blog/a/b/data.json", "data"),