"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "markup/markup_config/config_test.go" between
hugo-0.80.0.tar.gz and hugo-0.81.0.tar.gz

About: Hugo is a static site generator that takes a source directory of Markdown files and templates and uses these as input to create a complete website (written in Go).

config_test.go  (hugo-0.80.0):config_test.go  (hugo-0.81.0)
skipping to change at line 49 skipping to change at line 49
"safeMode": "save", "safeMode": "save",
"extensions": []string{"asciidoctor-htm l5s"}, "extensions": []string{"asciidoctor-htm l5s"},
}, },
}) })
conf, err := Decode(v) conf, err := Decode(v)
c.Assert(err, qt.IsNil) c.Assert(err, qt.IsNil)
c.Assert(conf.Goldmark.Renderer.Unsafe, qt.Equals, true) c.Assert(conf.Goldmark.Renderer.Unsafe, qt.Equals, true)
c.Assert(conf.BlackFriday.Fractions, qt.Equals, true) c.Assert(conf.BlackFriday.Fractions, qt.Equals, true)
c.Assert(conf.Goldmark.Parser.Attribute.Title, qt.Equals, true)
c.Assert(conf.Goldmark.Parser.Attribute.Block, qt.Equals, false)
c.Assert(conf.AsciidocExt.WorkingFolderCurrent, qt.Equals, true) c.Assert(conf.AsciidocExt.WorkingFolderCurrent, qt.Equals, true)
c.Assert(conf.AsciidocExt.Extensions[0], qt.Equals, "asciidoctor- html5s") c.Assert(conf.AsciidocExt.Extensions[0], qt.Equals, "asciidoctor- html5s")
}) })
c.Run("legacy", func(c *qt.C) { c.Run("legacy", func(c *qt.C) {
c.Parallel() c.Parallel()
v := viper.New() v := viper.New()
v.Set("blackfriday", map[string]interface{}{ v.Set("blackfriday", map[string]interface{}{
"angledQuotes": true, "angledQuotes": true,
}) })
v.Set("footnoteAnchorPrefix", "myprefix") v.Set("footnoteAnchorPrefix", "myprefix")
v.Set("footnoteReturnLinkContents", "myreturn") v.Set("footnoteReturnLinkContents", "myreturn")
v.Set("pygmentsStyle", "hugo") v.Set("pygmentsStyle", "hugo")
v.Set("pygmentsCodefencesGuessSyntax", true) v.Set("pygmentsCodefencesGuessSyntax", true)
v.Set("markup", map[string]interface{}{
"goldmark": map[string]interface{}{
"parser": map[string]interface{}{
"attribute": false, // Was changed to a s
truct in 0.81.0
},
},
})
conf, err := Decode(v) conf, err := Decode(v)
c.Assert(err, qt.IsNil) c.Assert(err, qt.IsNil)
c.Assert(conf.BlackFriday.AngledQuotes, qt.Equals, true) c.Assert(conf.BlackFriday.AngledQuotes, qt.Equals, true)
c.Assert(conf.BlackFriday.FootnoteAnchorPrefix, qt.Equals, "mypre fix") c.Assert(conf.BlackFriday.FootnoteAnchorPrefix, qt.Equals, "mypre fix")
c.Assert(conf.BlackFriday.FootnoteReturnLinkContents, qt.Equals, "myreturn") c.Assert(conf.BlackFriday.FootnoteReturnLinkContents, qt.Equals, "myreturn")
c.Assert(conf.Highlight.Style, qt.Equals, "hugo") c.Assert(conf.Highlight.Style, qt.Equals, "hugo")
c.Assert(conf.Highlight.CodeFences, qt.Equals, true) c.Assert(conf.Highlight.CodeFences, qt.Equals, true)
c.Assert(conf.Highlight.GuessSyntax, qt.Equals, true) c.Assert(conf.Highlight.GuessSyntax, qt.Equals, true)
c.Assert(conf.Goldmark.Parser.Attribute.Title, qt.Equals, false)
c.Assert(conf.Goldmark.Parser.Attribute.Block, qt.Equals, false)
}) })
} }
 End of changes. 3 change blocks. 
0 lines changed or deleted 14 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)