17 if [ "$persist" = "true" ]; then
24 if [ "$debug" = "true" ]; then
31 if [ "$verbose" = "true" ]; then
37 if [ "$unconfigure" = "true" ]; then
38 args="$args -unconfigure"
43 args="$args -cpus ${i#*=}"
46 args="$args -vppsrc ${i#*=}"
50 if [ "$tc_name" != "all" ]; then
52 ginkgo_args="$ginkgo_args --focus $tc_name -vv"
55 ginkgo_args="$ginkgo_args -v"
59 ginkgo_args="$ginkgo_args -procs=${i#*=}"
62 ginkgo_args="$ginkgo_args --repeat=${i#*=}"
67 if [ $single_test -eq 0 ] && [ $persist_set -eq 1 ]; then
68 echo "persist flag is not supported while running all tests!"
72 if [ $unconfigure_set -eq 1 ] && [ $single_test -eq 0 ]; then
73 echo "a single test has to be specified when unconfigure is set"
77 if [ $persist_set -eq 1 ] && [ $unconfigure_set -eq 1 ]; then
78 echo "setting persist flag and unconfigure flag is not allowed"
82 if [ $single_test -eq 0 ] && [ $debug_set -eq 1 ]; then
83 echo "VPP debug flag is not supperted while running all tests!"
88 # shellcheck disable=SC2086
89 sudo -E go run github.com/onsi/ginkgo/v2/ginkgo --no-color --trace --json-report=summary/report.json $ginkgo_args -- $args
91 jq -r '.[0] | .SpecReports[] | select((.State == "failed") or (.State == "timedout") or (.State == "panicked")) | select(.Failure != null) | "TestName: \(.LeafNodeText)\nSuite:\n\(.Failure.Location.FileName)\nMessage:\n\(.Failure.Message)\n Full Stack Trace:\n\(.Failure.Location.FullStackTrace)\n"' summary/report.json > summary/failed-summary.log \
92 && echo "Summary generated -> summary/failed-summary.log"