aboutsummaryrefslogtreecommitdiffstats
path: root/tests/blogc-make/check_blogc_make.sh.in
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2017-01-03 03:15:07 +0100
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2017-01-03 03:15:07 +0100
commita4bddf83cbbac86c3734b8c399e65c7341385a85 (patch)
tree4682d345d352c9e285925c8a073fcc72ad22fc02 /tests/blogc-make/check_blogc_make.sh.in
parentaa8871ffe2e335b6f4a5107c15e978ba99a9fae5 (diff)
downloadblogc-a4bddf83cbbac86c3734b8c399e65c7341385a85.tar.gz
blogc-a4bddf83cbbac86c3734b8c399e65c7341385a85.tar.bz2
blogc-a4bddf83cbbac86c3734b8c399e65c7341385a85.zip
blogc-make: fixed clean rule
Diffstat (limited to 'tests/blogc-make/check_blogc_make.sh.in')
-rwxr-xr-xtests/blogc-make/check_blogc_make.sh.in65
1 files changed, 64 insertions, 1 deletions
diff --git a/tests/blogc-make/check_blogc_make.sh.in b/tests/blogc-make/check_blogc_make.sh.in
index b043049..638b149 100755
--- a/tests/blogc-make/check_blogc_make.sh.in
+++ b/tests/blogc-make/check_blogc_make.sh.in
@@ -795,4 +795,67 @@ Page 2
EOF
diff -uN "${TEMP}/proj/_blogc_build/page2.html" "${TEMP}/expected-page2.html"
-rm -rf "${TEMP}/proj/_blogc_build"
+
+### clean rule
+
+${TESTS_ENVIRONMENT} @abs_top_builddir@/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"
+grep "_blogc_build/atoom/tag2/index\\.xml" "${TEMP}/output.txt"
+grep "_blogc_build/pagination/1\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/pagination/2\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/pagination/3\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/poost/foo\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/poost/bar\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/poost/baz\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/taag/tag1\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/taag/tag2\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/page1\\.html" "${TEMP}/output.txt"
+grep "_blogc_build/page2\\.html" "${TEMP}/output.txt"
+
+rm "${TEMP}/output.txt"
+
+[[ ! -d "${TEMP}/proj/_blogc_build" ]]
+
+export OUTPUT_DIR="${TEMP}/___blogc_build"
+
+${TESTS_ENVIRONMENT} @abs_top_builddir@/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"
+grep "___blogc_build/atoom/tag2/index\\.xml" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/2\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/3\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/foo\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/bar\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/baz\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/taag/tag1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/taag/tag2\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/page1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/page2\\.html" "${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"
+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"
+grep "___blogc_build/atoom/tag2/index\\.xml" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/2\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/pagination/3\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/foo\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/bar\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/poost/baz\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/taag/tag1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/taag/tag2\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/page1\\.html" "${TEMP}/output.txt"
+grep "___blogc_build/page2\\.html" "${TEMP}/output.txt"
+
+rm "${TEMP}/output.txt"
+
+[[ ! -d "${OUTPUT_DIR}" ]]
+
+unset OUTPUT_DIR