2 # SPDX-License-Identifier: BSD-3-Clause
6 if [ $(id -u) -ne 0 ]; then
11 # check python requirements
12 python3 ${DIR}/pkttest.py check_reqs
14 echo "Requirements for Python not met, exiting"
18 # secgw application parameters setup
19 CRYPTO_DEV="--vdev=crypto_null0"
20 SGW_PORT_CFG="--vdev=net_tap0,mac=fixed --vdev=net_tap1,mac=fixed"
21 SGW_EAL_XPRM="--no-pci"
24 . ${DIR}/common_defs_secgw.sh
26 echo "Running tests: $*"
29 # check test file presence
30 testfile="${DIR}/${testcase}.py"
31 if [ ! -f ${testfile} ]; then
32 echo "Invalid test ${testcase}"
37 python3 ${testfile} config > ${SGW_CFG_FILE}
40 echo "Cannot get secgw configuration for test ${testcase}"
44 # start the application
52 echo "Running test case: ${testcase}"
56 # stop the application
59 # report test result and exit on failure
60 if [ $st -eq 0 ]; then
61 echo "Test case ${testcase} succeeded"
63 echo "Test case ${testcase} failed!"