summaryrefslogtreecommitdiffstats
path: root/hugolib/hugo_modules_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'hugolib/hugo_modules_test.go')
-rw-r--r--hugolib/hugo_modules_test.go28
1 files changed, 28 insertions, 0 deletions
diff --git a/hugolib/hugo_modules_test.go b/hugolib/hugo_modules_test.go
index 73a3d2db0..66b3609af 100644
--- a/hugolib/hugo_modules_test.go
+++ b/hugolib/hugo_modules_test.go
@@ -506,3 +506,31 @@ weight = 2
}
}
}
+
+func TestMountsProject(t *testing.T) {
+
+ config := `
+
+baseURL="https://example.org"
+
+[module]
+[[module.mounts]]
+source="mycontent"
+target="content"
+
+`
+ b := newTestSitesBuilder(t).
+ WithConfigFile("toml", config).
+ WithSourceFile(filepath.Join("mycontent", "mypage.md"), `
+---
+title: "My Page"
+---
+
+`)
+
+ b.Build(BuildCfg{})
+
+ //helpers.PrintFs(b.H.Fs.Source, "public", os.Stdout)
+
+ b.AssertFileContent("public/mypage/index.html", "Permalink: https://example.org/mypage/")
+}