add test for run --ip

Signed-off-by: Victor Vieux <vieux@docker.com>
This commit is contained in:
Victor Vieux 2016-01-29 01:16:48 -08:00
parent f7c7ec09f8
commit 9abd727c52
1 changed files with 11 additions and 0 deletions

View File

@ -101,6 +101,17 @@ function teardown() {
[[ "${output}" == *"\"StopSignal\": \"SIGKILL\""* ]] [[ "${output}" == *"\"StopSignal\": \"SIGKILL\""* ]]
} }
@test "docker run --ip" {
start_docker_with_busybox 1
swarm_manage
docker_swarm network create -d bridge --subnet 10.0.0.0/24 testn
docker_swarm run --name testc --net testn -d --ip 10.0.0.42 busybox sh
run docker_swarm inspect testc
[[ "${output}" == *"10.0.0.42"* ]]
}
@test "docker run - reschedule with image affinity" { @test "docker run - reschedule with image affinity" {
start_docker_with_busybox 1 start_docker_with_busybox 1
start_docker 1 start_docker 1