fix in daemon side

Signed-off-by: Zhang Kun <zkazure@gmail.com>

goformat

Signed-off-by: Zhang Kun <zkazure@gmail.com>

fix small

Signed-off-by: Zhang Kun <zkazure@gmail.com>

change to rm

Signed-off-by: Zhang Kun <zkazure@gmail.com>

handler other error

Signed-off-by: Zhang Kun <zkazure@gmail.com>

unique ERR

Signed-off-by: Zhang Kun <zkazure@gmail.com>

setHostConfig_fail_test

Signed-off-by: Zhang Kun <zkazure@gmail.com>

format

Signed-off-by: Zhang Kun <zkazure@gmail.com>

err handle and modify test

Signed-off-by: Zhang Kun <zkazure@gmail.com>

golint error

Signed-off-by: Zhang Kun <zkazure@gmail.com>
Upstream-commit: 1ed15550f57ae822bb30263ce81174cabeb794ec
Component: engine
This commit is contained in:
Zhang Kun
2015-08-18 10:06:36 +08:00
parent 427a3b4bda
commit a3521c2e7e
2 changed files with 19 additions and 1 deletions
@@ -2816,3 +2816,13 @@ func (s *DockerSuite) TestRunCapAddSYSTIME(c *check.C) {
dockerCmd(c, "run", "--cap-drop=ALL", "--cap-add=SYS_TIME", "busybox", "sh", "-c", "grep ^CapEff /proc/self/status | sed 's/^CapEff:\t//' | grep ^0000000002000000$")
}
// run create container failed should clean up the container
func (s *DockerSuite) TestRunCreateContainerFailedCleanUp(c *check.C) {
name := "unique_name"
_, _, err := dockerCmdWithError("run", "--name", name, "--link", "nothing:nothing", "busybox")
c.Assert(err, check.Not(check.IsNil), check.Commentf("Expected docker run to fail!"))
containerID, err := inspectField(name, "Id")
c.Assert(containerID, check.Equals, "", check.Commentf("Expected not to have this container: %s!", containerID))
}