ngx-awesomeindex/t/08-local-footer.test

17 lines
401 B
Bash

#! /bin/bash
cat <<---
This test checks that a local footer can be included with
"awesomeindex_header ... local".
--
use pup
cat > "${TESTDIR}/footer" <<EOF
<div id="customfooter">yes</div>
EOF
nginx_start "awesomeindex_footer \"${TESTDIR}/footer\" local;"
T=$(fetch / | pup -p body 'div#customfooter' text{})
[[ $T == yes ]] || fail 'Custom header missing'
nginx_is_running || fail 'Nginx died'