summaryrefslogtreecommitdiff
path: root/tests/tableopts.sh
diff options
context:
space:
mode:
authorExplorer09 <explorer09@gmail.com>2017-01-02 09:03:12 +0800
committerWill Estes <westes575@gmail.com>2017-01-17 21:10:16 -0500
commitbcf7a07369f3d407378c3980f5411459f07a111f (patch)
tree3f45bbd6f41abd8b65533bc0266759741866fb87 /tests/tableopts.sh
parent8c8691c3fdb327eb45d5ee831da62e7433563004 (diff)
test: Remove test scripts bashisms.
They now all work under a POSIX compliant sh. Specifically, 'dash' can now be used for running "make check" tests. Note that none of these scripts has ever been using a pipe, so `set -o pipefail` is unnecessary and removed.
Diffstat (limited to 'tests/tableopts.sh')
-rwxr-xr-xtests/tableopts.sh15
1 files changed, 9 insertions, 6 deletions
diff --git a/tests/tableopts.sh b/tests/tableopts.sh
index 63a36d3..52f3ac1 100755
--- a/tests/tableopts.sh
+++ b/tests/tableopts.sh
@@ -1,12 +1,15 @@
-#!/bin/bash
-set -euo pipefail
-IFS=$'\n\t'
+#!/bin/sh
+set -eu
+# IFS=$'\n\t'
+IFS='
+'' '
# This script is present to generate the automake _SOURCES variables
# for the tableopts_* tests. It also generates the linking rules for
# each test since automake isn't able to handle the pattern rules that
# would be natural to use. Output is written to standard output for
-# inclusion in a Makefile.am, typically by redirecting the output and then an automake include directive.
+# inclusion in a Makefile.am, typically by redirecting the output and
+# then an automake include directive.
TABLEOPTS_TESTS=""
tableopts_tables=""
@@ -17,12 +20,12 @@ for kind in opt ser ver ; do
testname=tableopts_${kind}_${threading}${opt}.${kind}
if [ "${TABLEOPTS_TESTS}" = "" ] ;then
TABLEOPTS_TESTS=${testname}
- if [ "$kind" = "ser" -o "$kind" = "ver" ] ; then
+ if [ "$kind" = "ser" ] || [ "$kind" = "ver" ] ; then
tableopts_tables=${testname}.tables
fi
else
TABLEOPTS_TESTS="${TABLEOPTS_TESTS} ${testname}"
- if [ "$kind" = "ser" -o "$kind" = "ver" ] ; then
+ if [ "$kind" = "ser" ] || [ "$kind" = "ver" ] ; then
tableopts_tables="${tableopts_tables} ${testname}.tables"
fi
fi