Skip to content

Commit

Permalink
Create tmon-logs.tgz
Browse files Browse the repository at this point in the history
  • Loading branch information
ThinkerYzu1 committed Aug 15, 2024
1 parent c68ac07 commit f542c73
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions ci/vmtest/vmtest_selftests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ WORKING_DIR="/${PROJECT_NAME}"
BPF_SELFTESTS_DIR="${WORKING_DIR}/selftests/bpf"
VMTEST_CONFIGS_PATH="${WORKING_DIR}/ci/vmtest/configs"
PKG_CONFIG=pkg-config
TMON_DIR=/tmp/tmon_pcap

read_lists() {
(for path in "$@"; do
Expand Down Expand Up @@ -189,6 +190,10 @@ echo "TMONLIST: ${TMONLIST}"
cd ${PROJECT_NAME}/selftests/bpf
if [ -d "${TMON_DIR}" ]; then
rm -rf "${TMON_DIR}"
fi
# populate TEST_NAMES
read_test_names "$@"
# if we don't have any test name provided to the script, we run all tests.
Expand All @@ -205,3 +210,8 @@ else
"${test_name}"
done
fi
if [ -d /tmp/tmon_pcap ]; then
tar zcvf ${OUTPUT_DIR}/tmon-logs.tgz "${TMON_DIR}" > /dev/null 2>&1
rm -rf "${TMON_DIR}"
fi

0 comments on commit f542c73

Please sign in to comment.