+
+#
+# Log a message (on all nodes) padded with "=" before and after.
+# Also appends a timestamp and prepends the testsuite name.
+#
+banner() {
+ msg="== ${TESTSUITE} $*"
+ # pad the message out to 70 with "="
+ last=${msg: -1:1}
+ [[ $last != "=" && $last != " " ]] && msg+=" "
+ for i in $(seq $((68 - ${#msg})) ); do
+ msg+="="
+ done
+ # always include at least == after the message
+ msg+="=="
+
+ log "$msg $(date +"%H:%M:%S (%s)")"
+}
+
+#
+# Run a single test function and cleanup after it.
+#
+# This function should be run in a subshell so the test func can
+# exit() without stopping the whole script.
+#