Skip to content

Commit

Permalink
add test to ensure the markdown has priority or assets
Browse files Browse the repository at this point in the history
  • Loading branch information
jtarchie committed Sep 27, 2023
1 parent 27a8e49 commit 4b9dc16
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions builder_suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -242,4 +242,23 @@ title: required
Eventually(buffer).Should(gbytes.Say(`<h2 id=h2-heading><a class=anchor href=#h2-heading>#</a> h2 Heading</h2>`))
})
})

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`))
})
})
})

0 comments on commit 4b9dc16

Please sign in to comment.