diff --git a/test/integration/api/network.bats b/test/integration/api/network.bats index c6b797f363..f84834ba17 100644 --- a/test/integration/api/network.bats +++ b/test/integration/api/network.bats @@ -26,7 +26,7 @@ function teardown() { [ "$status" -ne 0 ] run docker_swarm network inspect node-0/bridge - [ "${#lines[@]}" -eq 23 ] + [[ "${output}" != *"\"containers\": {}"* ]] } @test "docker network create" { @@ -75,20 +75,20 @@ function teardown() { docker_swarm run -d --name test_container -e constraint:node==node-0 busybox sleep 100 run docker_swarm network inspect node-0/bridge - [ "${#lines[@]}" -eq 23 ] + [[ "${output}" != *"\"containers\": {}"* ]] docker_swarm network disconnect node-0/bridge test_container run docker_swarm network inspect node-0/bridge - [ "${#lines[@]}" -eq 16 ] + [[ "${output}" == *"\"containers\": {}"* ]] docker_swarm network connect node-0/bridge test_container run docker_swarm network inspect node-0/bridge - [ "${#lines[@]}" -eq 23 ] + [[ "${output}" != *"\"containers\": {}"* ]] docker_swarm rm -f test_container run docker_swarm network inspect node-0/bridge - [ "${#lines[@]}" -eq 16 ] + [[ "${output}" == *"\"containers\": {}"* ]] }