Commit 4a075bd4 authored by Masami Hiramatsu's avatar Masami Hiramatsu Committed by Shuah Khan

selftests/ftrace: Add checkbashisms meta-testcase

Add a meta-testcase which tests ftracetest itself with
checkbasisms. This helps us to keep our test script
bashisms clean.
Signed-off-by: default avatarMasami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: default avatarShuah Khan <skhan@linuxfoundation.org>
parent 3fda9b33
......@@ -318,6 +318,7 @@ run_test() { # testfile
local testlog=/proc/self/fd/1
fi
export TMPDIR=`mktemp -d /tmp/ftracetest-dir.XXXXXX`
export FTRACETEST_ROOT=$TOP_DIR
echo "execute$INSTANCE: "$1 > $testlog
SIG_RESULT=0
if [ $VERBOSE -eq -1 ]; then
......
#!/bin/sh
# SPDX-License-Identifier: GPL-2.0
# description: Meta-selftest: Checkbashisms
if [ ! -f $FTRACETEST_ROOT/ftracetest ]; then
echo "Hmm, we can not find ftracetest"
exit_unresolved
fi
if ! which checkbashisms > /dev/null 2>&1 ; then
echo "No checkbashisms found. skipped."
exit_unresolved
fi
checkbashisms $FTRACETEST_ROOT/ftracetest
checkbashisms $FTRACETEST_ROOT/test.d/functions
for t in $(find $FTRACETEST_ROOT/test.d -name \*.tc); do
checkbashisms $t
done
exit 0
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment