A "coreutil" static site generator
1# vim: ft=sh
2# shellcheck shell=bash
3
4make_site() { #@test
5 cd ./tests/make || exit 1
6
7 run make
8
9 test -f index.html
10 test "$(cat index.html)" = "<h1>TEST</h1>"
11
12 run make clean
13
14 test ! -f index.html
15}
16
17make_with_layout() { #@test
18 cd ./tests/make || exit 1
19
20 run make layout=layout.html
21
22 test -f index.html
23 test "$(cat index.html)" = "<body><h1>TEST</h1></body>"
24
25 run make clean
26
27 test ! -f index.html
28}