From 4b9dc1601aa70025f056bd6d050d0c166a2fe9fa Mon Sep 17 00:00:00 2001 From: JT Archie Date: Wed, 27 Sep 2023 10:03:23 -0600 Subject: [PATCH] add test to ensure the markdown has priority or assets --- builder_suite_test.go | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/builder_suite_test.go b/builder_suite_test.go index 5b02b15..ec2de20 100644 --- a/builder_suite_test.go +++ b/builder_suite_test.go @@ -242,4 +242,23 @@ title: required Eventually(buffer).Should(gbytes.Say(`

# h2 Heading

`)) }) }) + + When("using asset path", func() { + It("copies all files", func() { + createLayout() + createFile("dir/index.md", "# some text") + createFile("dir/test.html", "some other text") + + cli.AssetsPath = cli.SourcePath + + err := cli.Run() + Expect(err).NotTo(HaveOccurred()) + + contents := readFile("dir/test.html") + Expect(contents).To(gbytes.Say(`some other text`)) + + contents = readFile("dir/index.html") + Expect(contents).To(gbytes.Say(`some text`)) + }) + }) })