diff options
Diffstat (limited to 'helpers/url_test.go')
-rw-r--r-- | helpers/url_test.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/helpers/url_test.go b/helpers/url_test.go index 4072b40e2..8dbec3f7c 100644 --- a/helpers/url_test.go +++ b/helpers/url_test.go @@ -248,7 +248,10 @@ func TestURLPrep(t *testing.T) { {true, "/section/name/index.html", "/section/name.html"}, } for i, d := range data { - output := URLPrep(d.ugly, d.input) + viper.Set("uglyURLs", d.ugly) + p := NewPathSpecFromConfig(viper.GetViper()) + + output := p.URLPrep(d.input) if d.output != output { t.Errorf("Test #%d failed. Expected %q got %q", i, d.output, output) } |