aboutsummaryrefslogtreecommitdiffhomepage
path: root/hugolib/site_test.go
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <[email protected]>2018-07-18 19:58:39 +0200
committerBjørn Erik Pedersen <[email protected]>2018-07-19 14:32:43 +0200
commite25aa655f4227ac064be5fe770d517a80acd46b2 (patch)
treed5826566794ba8acba57fda155d56ba3d844fbad /hugolib/site_test.go
parent12679b408362a93a3c6159588d6291a3b7ed5548 (diff)
downloadhugo-e25aa655f4227ac064be5fe770d517a80acd46b2.tar.gz
hugo-e25aa655f4227ac064be5fe770d517a80acd46b2.zip
Add configurable ref/relref error handling and notFoundURL
Two new settings: * refLinksErrorLevel: ERROR (default) or WARNING. ERROR will fail the build. * refLinksNotFoundURL: Used as a placeholder when page references cannot be found. Fixes #4964
Diffstat (limited to 'hugolib/site_test.go')
-rw-r--r--hugolib/site_test.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/hugolib/site_test.go b/hugolib/site_test.go
index 202c01986..7787ea2a4 100644
--- a/hugolib/site_test.go
+++ b/hugolib/site_test.go
@@ -925,7 +925,7 @@ func TestRefLinking(t *testing.T) {
{"level2/common.md", "", true, "/level2/common/"},
{"3-root.md", "", true, "/level2/level3/3-root/"},
} {
- if out, err := site.Info.refLink(test.link, currentPage, test.relative, test.outputFormat); err != nil || out != test.expected {
+ if out, err := site.refLink(test.link, currentPage, test.relative, test.outputFormat); err != nil || out != test.expected {
t.Errorf("[%d] Expected %s to resolve to (%s), got (%s) - error: %s", i, test.link, test.expected, out, err)
}
}