Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
- fix missing SLIRP_CONFIG_VERSION_MAX in test scripts
  • Loading branch information
pfandl committed Sep 11, 2021
1 parent 346fb19 commit 880471f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/test-slirp4netns-hostfwd4.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ set -xeuo pipefail

. $(dirname $0)/common.sh

SLIRP_CONFIG_VERSION_MAX=$(slirp4netns -v | grep "SLIRP_CONFIG_VERSION_MAX: " | sed 's#SLIRP_CONFIG_VERSION_MAX: \(\)##')

if [ "${SLIRP_CONFIG_VERSION_MAX:-0}" -lt 3 ]; then
printf "forwarding test requires SLIRP_CONFIG_VERSION_MAX 3 or newer. Test skipped..."
exit "$TEST_EXIT_CODE_SKIP"
Expand Down
2 changes: 2 additions & 0 deletions tests/test-slirp4netns-hostfwd6.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ set -xeuo pipefail

. $(dirname $0)/common.sh

SLIRP_CONFIG_VERSION_MAX=$(slirp4netns -v | grep "SLIRP_CONFIG_VERSION_MAX: " | sed 's#SLIRP_CONFIG_VERSION_MAX: \(\)##')

if [ "${SLIRP_CONFIG_VERSION_MAX:-0}" -lt 3 ]; then
printf "forwarding test requires SLIRP_CONFIG_VERSION_MAX 3 or newer. Test skipped..."
exit "$TEST_EXIT_CODE_SKIP"
Expand Down
2 changes: 2 additions & 0 deletions tests/test-slirp4netns-ipv6.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ set -xeuo pipefail

. $(dirname $0)/common.sh

SLIRP_CONFIG_VERSION_MAX=$(slirp4netns -v | grep "SLIRP_CONFIG_VERSION_MAX: " | sed 's#SLIRP_CONFIG_VERSION_MAX: \(\)##')

if [ "${SLIRP_CONFIG_VERSION_MAX:-0}" -lt 3 ]; then
printf "ipv6 test requires SLIRP_CONFIG_VERSION_MAX 3 or newer. Test skipped..."
exit "$TEST_EXIT_CODE_SKIP"
Expand Down

0 comments on commit 880471f

Please sign in to comment.