#!/bin/sh cd /opt/ltp >/dev/null addgroup nobody sed -i -e "/mounts | sort -b$/s/$/ | grep -v deleted/" ./testscripts/test_fs_bind.sh logname=`date +"%Y_%m_%d_%H_%M_%S"`".log" ./runltp -p -d /tmp -l $logname if [ ! -d ./results ]; then echo "FAIL: no result found" exit 1 fi cat ./results/$logname | while read line do resultLine=`echo $line | grep -c -E "PASS|FAIL"` if [ $resultLine -eq 1 ]; then testcase=`echo $line | awk '{print $1}'` result=`echo $line | awk '{print $2}'` echo "$result: $testcase" fi done