integration-cli: remove defaultSleepImage constant

Both Linux and Windows now use busybox, so no need to keep a
constant for this.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2019-07-08 18:42:08 +02:00
parent 4abac69dc6
commit 27f432ca57
No known key found for this signature in database
GPG Key ID: 76698F39D527CE8C
5 changed files with 4 additions and 12 deletions

View File

@ -28,7 +28,7 @@ func (s *DockerSuite) BenchmarkConcurrentContainerActions(c *check.C) {
go func() {
defer innerGroup.Done()
for i := 0; i < numIterations; i++ {
args := []string{"run", "-d", defaultSleepImage}
args := []string{"run", "-d", "busybox"}
args = append(args, sleepCommandForDaemonPlatform()...)
out, _, err := dockerCmdWithError(args...)
if err != nil {

View File

@ -14,11 +14,11 @@ func (s *DockerSwarmSuite) TestServiceScale(c *check.C) {
d := s.AddDaemon(c, true, true)
service1Name := "TestService1"
service1Args := append([]string{"service", "create", "--detach", "--no-resolve-image", "--name", service1Name, defaultSleepImage}, sleepCommandForDaemonPlatform()...)
service1Args := append([]string{"service", "create", "--detach", "--no-resolve-image", "--name", service1Name, "busybox"}, sleepCommandForDaemonPlatform()...)
// global mode
service2Name := "TestService2"
service2Args := append([]string{"service", "create", "--detach", "--no-resolve-image", "--name", service2Name, "--mode=global", defaultSleepImage}, sleepCommandForDaemonPlatform()...)
service2Args := append([]string{"service", "create", "--detach", "--no-resolve-image", "--name", service2Name, "--mode=global", "busybox"}, sleepCommandForDaemonPlatform()...)
// Create services
_, err := d.Cmd(service1Args...)

View File

@ -347,7 +347,7 @@ func getInspectBody(c *check.C, version, id string) []byte {
// Run a long running idle task in a background container using the
// system-specific default image and command.
func runSleepingContainer(c *check.C, extraArgs ...string) string {
return runSleepingContainerInImage(c, defaultSleepImage, extraArgs...)
return runSleepingContainerInImage(c, "busybox", extraArgs...)
}
// Run a long running idle task in a background container using the specified

View File

@ -7,8 +7,4 @@ const (
isUnixCli = true
expectedFileChmod = "-rw-r--r--"
// On Unix variants, the busybox image comes with the `top` command which
// runs indefinitely while still being interruptible by a signal.
defaultSleepImage = "busybox"
)

View File

@ -8,8 +8,4 @@ const (
// this is the expected file permission set on windows: gh#11395
expectedFileChmod = "-rwxr-xr-x"
// On Windows, the busybox image doesn't have the `top` command, so we rely
// on `sleep` with a high duration.
defaultSleepImage = "busybox"
)