summaryrefslogtreecommitdiffstats
path: root/tests/blogc-make/check_blogc_make.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'tests/blogc-make/check_blogc_make.sh.in')
-rwxr-xr-xtests/blogc-make/check_blogc_make.sh.in47
1 files changed, 24 insertions, 23 deletions
diff --git a/tests/blogc-make/check_blogc_make.sh.in b/tests/blogc-make/check_blogc_make.sh.in
index d999840..429632c 100755
--- a/tests/blogc-make/check_blogc_make.sh.in
+++ b/tests/blogc-make/check_blogc_make.sh.in
@@ -7,7 +7,8 @@ set -xe -o pipefail
export LC_ALL=C
-export BLOGC=@abs_top_builddir@/blogc
+export BLOGC="@CMAKE_BINARY_DIR@/src/blogc/blogc"
+export BLOGC_MAKE="@_BLOGC_MAKE@"
TEMP="$(mktemp -d)"
[[ -n "${TEMP}" ]]
@@ -33,7 +34,7 @@ SITE_TAGLINE = WAT?!
BASE_DOMAIN = http://example.org
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1
### default settings with some posts
@@ -81,7 +82,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/page/1/index\\.html" "${TEMP}/output.txt"
@@ -198,7 +199,7 @@ post10
post11
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/post/post01/index\\.html" "${TEMP}/output.txt"
@@ -487,7 +488,7 @@ cat > "${TEMP}/proj/templates/atom.tmpl" <<EOF
</feed>
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/post/post01/index\\.html" "${TEMP}/output.txt"
@@ -695,7 +696,7 @@ post10
post11
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/post/post01/index\\.html" "${TEMP}/output.txt"
grep "_build/post/post02/index\\.html" "${TEMP}/output.txt"
grep "_build/post/post03/index\\.html" "${TEMP}/output.txt"
@@ -769,7 +770,7 @@ qwe
asd
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/post/post01/index\\.html" "${TEMP}/output.txt"
grep "_build/post/post02/index\\.html" "${TEMP}/output.txt"
grep "_build/post/post03/index\\.html" "${TEMP}/output.txt"
@@ -874,7 +875,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/page/1/index\\.html" "${TEMP}/output.txt"
@@ -981,7 +982,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/page/1/index\\.html" "${TEMP}/output.txt"
@@ -1096,7 +1097,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/page/1/index\\.html" "${TEMP}/output.txt"
@@ -1203,7 +1204,7 @@ tag1
tag2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/atom/tag1\\.xml" "${TEMP}/output.txt"
@@ -1408,7 +1409,7 @@ page1
page2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/atom\\.xml" "${TEMP}/output.txt"
grep "_build/atom/tag1\\.xml" "${TEMP}/output.txt"
@@ -1531,7 +1532,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/posts\\.html" "${TEMP}/output.txt"
grep "_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "_build/pagination/1\\.html" "${TEMP}/output.txt"
@@ -1631,7 +1632,7 @@ tag1
tag2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/posts\\.html" "${TEMP}/output.txt"
grep "_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -1780,7 +1781,7 @@ page1
page2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/posts\\.html" "${TEMP}/output.txt"
grep "_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -1864,7 +1865,7 @@ d/xd
f
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/posts\\.html" "${TEMP}/output.txt"
grep "_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -1903,7 +1904,7 @@ test "$(cat "${TEMP}/proj/_build/f/XDDDD")" = "FFFUUUUUU"
### clean rule
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" clean 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" clean 2>&1 | tee "${TEMP}/output.txt"
grep "_build/posts\\.html" "${TEMP}/output.txt"
grep "_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -1936,7 +1937,7 @@ rm "${TEMP}/output.txt"
export OUTPUT_DIR="${TEMP}/___blogc_build"
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "___blogc_build/posts\\.html" "${TEMP}/output.txt"
grep "___blogc_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "___blogc_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -1965,7 +1966,7 @@ grep "___blogc_build/f/XDDDD" "${TEMP}/output.txt"
rm "${TEMP}/output.txt"
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" clean 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" clean 2>&1 | tee "${TEMP}/output.txt"
grep "___blogc_build/posts\\.html" "${TEMP}/output.txt"
grep "___blogc_build/atoom/index\\.xml" "${TEMP}/output.txt"
grep "___blogc_build/atoom/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -2001,7 +2002,7 @@ unset OUTPUT_DIR
### atom_dump rule
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" atom_dump | tee "${TEMP}/atom.xml"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" atom_dump | tee "${TEMP}/atom.xml"
cat > "${TEMP}/expected-atom-dump.xml" <<EOF
<?xml version="1.0" encoding="utf-8"?>
@@ -2101,7 +2102,7 @@ foo
bar
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/index\\.xml" "${TEMP}/output.txt"
grep "_build/1/index\\.html" "${TEMP}/output.txt"
@@ -2231,7 +2232,7 @@ tag1
tag2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/index\\.xml" "${TEMP}/output.txt"
grep "_build/tag1/index\\.xml" "${TEMP}/output.txt"
@@ -2406,7 +2407,7 @@ page1
page2
EOF
-${TESTS_ENVIRONMENT} @abs_top_builddir@/blogc-make -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
+${TESTS_ENVIRONMENT} ${BLOGC_MAKE} -f "${TEMP}/proj/blogcfile" 2>&1 | tee "${TEMP}/output.txt"
grep "_build/index\\.html" "${TEMP}/output.txt"
grep "_build/index\\.xml" "${TEMP}/output.txt"
grep "_build/tag1/index\\.xml" "${TEMP}/output.txt"