Files
2026-02-04 17:39:32 +08:00

16 lines
363 B
Bash

#!/bin/bash
LOG_PATH=${LOG_PATH:-.}
files=($(ls benchmark_*.py))
for file in "${files[@]}"; do
echo "test ${file}..."
op_name=$(basename "$file" .py)
python "$file" > ${LOG_PATH}/${op_name}.log 2>&1
ret_tmp=$?
cat ${LOG_PATH}/${op_name}.log
if [ $ret_tmp != 0 ]; then
echo "${sc} test failed..."
exit $ret_tmp
fi
done