Deprecate -c cli short variant flag in docker run

Signed-off-by: Antonio Murdaca <runcom@linux.com>
This commit is contained in:
Antonio Murdaca
2015-09-17 15:48:48 +02:00
parent 3b168b29f2
commit e5a26ec081
3 changed files with 15 additions and 7 deletions
+4 -4
View File
@@ -217,9 +217,9 @@ func (s *DockerSuite) TestRunWithKernelMemory(c *check.C) {
// "test" should be printed
func (s *DockerSuite) TestRunEchoStdoutWitCPUShares(c *check.C) {
testRequires(c, cpuShare)
out, _ := dockerCmd(c, "run", "-c", "1000", "busybox", "echo", "test")
out, _ := dockerCmd(c, "run", "--cpu-shares", "1000", "busybox", "echo", "test")
if out != "test\n" {
c.Errorf("container should've printed 'test'")
c.Errorf("container should've printed 'test', got %q instead", out)
}
}
@@ -227,7 +227,7 @@ func (s *DockerSuite) TestRunEchoStdoutWitCPUShares(c *check.C) {
func (s *DockerSuite) TestRunEchoStdoutWithCPUSharesAndMemoryLimit(c *check.C) {
testRequires(c, cpuShare)
testRequires(c, memoryLimitSupport)
out, _, _ := dockerCmdWithStdoutStderr(c, "run", "-c", "1000", "-m", "16m", "busybox", "echo", "test")
out, _ := dockerCmd(c, "run", "--cpu-shares", "1000", "-m", "16m", "busybox", "echo", "test")
if out != "test\n" {
c.Errorf("container should've printed 'test', got %q instead", out)
}
@@ -291,7 +291,7 @@ func (s *DockerSuite) TestRunOOMExitCode(c *check.C) {
// "test" should be printed
func (s *DockerSuite) TestRunEchoStdoutWithMemoryLimit(c *check.C) {
testRequires(c, memoryLimitSupport)
out, _, _ := dockerCmdWithStdoutStderr(c, "run", "-m", "16m", "busybox", "echo", "test")
out, _ := dockerCmd(c, "run", "-m", "16m", "busybox", "echo", "test")
out = strings.Trim(out, "\r\n")
if expected := "test"; out != expected {