diff options
Diffstat (limited to 'automated/linux/ltp')
-rwxr-xr-x | automated/linux/ltp/ltp.sh | 11 | ||||
-rw-r--r-- | automated/linux/ltp/ltp.yaml | 4 |
2 files changed, 11 insertions, 4 deletions
diff --git a/automated/linux/ltp/ltp.sh b/automated/linux/ltp/ltp.sh index 521f228..c765293 100755 --- a/automated/linux/ltp/ltp.sh +++ b/automated/linux/ltp/ltp.sh @@ -15,15 +15,16 @@ TST_CMDFILES="" SKIPFILE="" # LTP version LTP_VERSION="20170516" +LTP_TMPDIR="" LTP_PATH=/opt/ltp usage() { - echo "Usage: ${0} [-T mm,math,syscalls] [-S skipfile-lsk-juno] [-s <flase>] [-v LTP_VERSION] [-M Timeout_Multiplier]" 1>&2 + echo "Usage: ${0} [-T mm,math,syscalls] [-S skipfile-lsk-juno] [-s <flase>] [-v LTP_VERSION] [-M Timeout_Multiplier] [-d LTP_TMPDIR]" 1>&2 exit 0 } -while getopts "M:T:S:s:v:" arg; do +while getopts "M:T:S:s:v:d:" arg; do case "$arg" in T) TST_CMDFILES="${OPTARG}" @@ -48,6 +49,10 @@ while getopts "M:T:S:s:v:" arg; do v) LTP_VERSION="${OPTARG}";; # Slow machines need more timeout Default is 5min and multiply * MINUTES M) export LTP_TIMEOUT_MUL="${OPTARG}";; + d) + mkdir -p "${OPTARG}" + LTP_TMPDIR="-d ${OPTARG}" + ;; esac done @@ -75,7 +80,7 @@ run_ltp() { # shellcheck disable=SC2164 cd "${LTP_PATH}" - pipe0_status "./runltp -p -q -f ${TST_CMDFILES} -l ${OUTPUT}/LTP_${LOG_FILE}.log -C ${OUTPUT}/LTP_${LOG_FILE}.failed ${SKIPFILE}" "tee ${OUTPUT}/LTP_${LOG_FILE}.out" + pipe0_status "./runltp -p -q -f ${TST_CMDFILES} -l ${OUTPUT}/LTP_${LOG_FILE}.log -C ${OUTPUT}/LTP_${LOG_FILE}.failed ${SKIPFILE}" "tee ${OUTPUT}/LTP_${LOG_FILE}.out ${LTP_TMPDIR}" check_return "runltp_${LOG_FILE}" parse_ltp_output "${OUTPUT}/LTP_${LOG_FILE}.log" diff --git a/automated/linux/ltp/ltp.yaml b/automated/linux/ltp/ltp.yaml index c4b8df3..c91cf08 100644 --- a/automated/linux/ltp/ltp.yaml +++ b/automated/linux/ltp/ltp.yaml @@ -31,11 +31,13 @@ params: SKIP_INSTALL: false # Slow machines need more timeout Default is 5min and multiply * TIMEOUT_MULTIPLIER TIMEOUT_MULTIPLIER: 1 + # Create LTP temporary files under LTP_TMPDIR while running test + LTP_TMPDIR: "" run: steps: - cd ./automated/linux/ltp/ - - ./ltp.sh -T "${TST_CMDFILES}" -S "${SKIPFILE}" -s "${SKIP_INSTALL}" -v "${LTP_VERSION}" -M "${TIMEOUT_MULTIPLIER}" + - ./ltp.sh -T "${TST_CMDFILES}" -S "${SKIPFILE}" -s "${SKIP_INSTALL}" -v "${LTP_VERSION}" -M "${TIMEOUT_MULTIPLIER}" -d "${LTP_TMPDIR}" - ../../utils/send-to-lava.sh ./output/result.txt parse: |