]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test: fix TEST-13-NSPAWN-SMOKE 7664/head
authorLennart Poettering <lennart@poettering.net>
Fri, 15 Dec 2017 19:49:11 +0000 (20:49 +0100)
committerLennart Poettering <lennart@poettering.net>
Fri, 15 Dec 2017 19:51:55 +0000 (20:51 +0100)
We need to specify a full path to the "ip" binary and busybox "ip" has a
slightly different output than the normal ip, and won't show "DOWN".
hence instead ensure that at lest not "UP" is in there.

test/TEST-13-NSPAWN-SMOKE/test.sh

index 239c7e0731e648c9131bab3531d9e16bc0abee6b..6a0cb42eaf8945a876f2ed258edd0f26ea717e30 100755 (executable)
@@ -147,7 +147,7 @@ function run {
     # test --network-namespace-path works with a network namespace created by "ip netns"
     ip netns add nspawn_test
     _netns_opt="--network-namespace-path=/run/netns/nspawn_test"
-    UNIFIED_CGROUP_HIERARCHY="$1" SYSTEMD_NSPAWN_USE_CGNS="$2" SYSTEMD_NSPAWN_API_VFS_WRITABLE="$3" systemd-nspawn --register=no -D "$_root" "$_netns_opt" ip a | grep -E '^1: lo.*DOWN'
+    UNIFIED_CGROUP_HIERARCHY="$1" SYSTEMD_NSPAWN_USE_CGNS="$2" SYSTEMD_NSPAWN_API_VFS_WRITABLE="$3" systemd-nspawn --register=no -D "$_root" "$_netns_opt" /bin/ip a | grep -v -E '^1: lo.*UP'
     local r=$?
     ip netns del nspawn_test