aboutsummaryrefslogtreecommitdiffstats
path: root/tests/blogc-make/check_blogc_make.sh.in
diff options
context:
space:
mode:
authorRafael G. Martins <rafael@rafaelmartins.eng.br>2019-04-03 01:44:14 +0200
committerRafael G. Martins <rafael@rafaelmartins.eng.br>2019-04-03 01:44:14 +0200
commit2c9cb299c6a137d8049afd28d851e5989f3192e1 (patch)
treef310e8936307fc2f05151c004bb865c3a915bfac /tests/blogc-make/check_blogc_make.sh.in
parent3afa72febc3d6ed7003d10f3a5c4211bf761d746 (diff)
downloadblogc-2c9cb299c6a137d8049afd28d851e5989f3192e1.tar.gz
blogc-2c9cb299c6a137d8049afd28d851e5989f3192e1.tar.bz2
blogc-2c9cb299c6a137d8049afd28d851e5989f3192e1.zip
make: added listing_entry test
Diffstat (limited to 'tests/blogc-make/check_blogc_make.sh.in')
-rwxr-xr-xtests/blogc-make/check_blogc_make.sh.in17
1 files changed, 14 insertions, 3 deletions
diff --git a/tests/blogc-make/check_blogc_make.sh.in b/tests/blogc-make/check_blogc_make.sh.in
index c62cd65..eea0cc7 100755
--- a/tests/blogc-make/check_blogc_make.sh.in
+++ b/tests/blogc-make/check_blogc_make.sh.in
@@ -59,7 +59,7 @@ EOF
done
cat > "${TEMP}/proj/templates/main.tmpl" <<EOF
-{% block listing %}
+{% block listing_entry %}{{ CONTENT }}{% endblock %}{% block listing %}
Listing: {% ifdef FILTER_TAG %}{{ FILTER_TAG }} - {% endif %}{{ TITLE }} - {{ DATE_FORMATTED }}
{% endblock %}
{% block entry %}
@@ -755,7 +755,13 @@ diff -uN "${TEMP}/proj/_build/post/post11/index.html" "${TEMP}/expected-post-pos
rm -rf "${TEMP}/proj/_build"
-### default settings with some posts, order asc
+### default settings with some posts, order asc, listing_entry
+
+cat > "${TEMP}/proj/content/hue.txt" <<EOF
+TITLE: Hue
+----------------
+This is hue.
+EOF
cat > "${TEMP}/proj/blogcfile" <<EOF
[global]
@@ -768,6 +774,7 @@ BASE_DOMAIN = http://example.org
[settings]
html_order = ASC
atom_order = ASC
+listing_entry = hue
[posts]
foo
@@ -784,6 +791,7 @@ grep "_build/post/bar/index\\.html" "${TEMP}/output.txt"
rm "${TEMP}/output.txt"
cat > "${TEMP}/expected-index.html" <<EOF
+<p>This is hue.</p>
Listing: Foo - Oct 01, 2016, 12:00 AM GMT
@@ -865,7 +873,7 @@ diff -uN "${TEMP}/proj/_build/post/bar/index.html" "${TEMP}/expected-post-bar.ht
rm -rf "${TEMP}/proj/_build"
-### default settings with some posts and tags, order asc
+### default settings with some posts and tags, order asc, listing_entry
cat > "${TEMP}/proj/content/post/baz.txt" <<EOF
TITLE: Baz
@@ -897,6 +905,7 @@ grep "_build/tag/tag2/index\\.html" "${TEMP}/output.txt"
rm "${TEMP}/output.txt"
cat > "${TEMP}/expected-index.html" <<EOF
+<p>This is hue.</p>
Listing: Foo - Oct 01, 2016, 12:00 AM GMT
@@ -1047,6 +1056,7 @@ diff -uN "${TEMP}/proj/_build/post/bar/index.html" "${TEMP}/expected-post-bar.ht
diff -uN "${TEMP}/proj/_build/post/baz/index.html" "${TEMP}/expected-post-baz.html"
cat > "${TEMP}/expected-tag1.html" <<EOF
+<p>This is hue.</p>
Listing: tag1 - Baz - Aug 01, 2016, 12:00 AM GMT
@@ -1055,6 +1065,7 @@ EOF
diff -uN "${TEMP}/proj/_build/tag/tag1/index.html" "${TEMP}/expected-tag1.html"
cat > "${TEMP}/expected-tag2.html" <<EOF
+<p>This is hue.</p>
Listing: tag2 - Baz - Aug 01, 2016, 12:00 AM GMT