mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #13347 from fntlnz/13184-remove-delete-container
Removed deleteContainer calls
This commit is contained in:
commit
c696993452
5 changed files with 0 additions and 42 deletions
|
@ -31,9 +31,6 @@ func (s *DockerSuite) TestKillContainer(c *check.C) {
|
|||
if strings.Contains(out, cleanedContainerID) {
|
||||
c.Fatal("killed container is still running")
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestKillDifferentUserContainer(c *check.C) {
|
||||
|
@ -60,7 +57,4 @@ func (s *DockerSuite) TestKillDifferentUserContainer(c *check.C) {
|
|||
if strings.Contains(out, cleanedContainerID) {
|
||||
c.Fatal("killed container is still running")
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
|
|
@ -35,9 +35,6 @@ func (s *DockerSuite) TestLogsContainerSmallerThanPage(c *check.C) {
|
|||
if len(out) != testLen+1 {
|
||||
c.Fatalf("Expected log length of %d, received %d\n", testLen+1, len(out))
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
// Regression test: When going over the PageSize, it used to panic (gh#4851)
|
||||
|
@ -61,9 +58,6 @@ func (s *DockerSuite) TestLogsContainerBiggerThanPage(c *check.C) {
|
|||
if len(out) != testLen+1 {
|
||||
c.Fatalf("Expected log length of %d, received %d\n", testLen+1, len(out))
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
// Regression test: When going much over the PageSize, it used to block (gh#4851)
|
||||
|
@ -87,9 +81,6 @@ func (s *DockerSuite) TestLogsContainerMuchBiggerThanPage(c *check.C) {
|
|||
if len(out) != testLen+1 {
|
||||
c.Fatalf("Expected log length of %d, received %d\n", testLen+1, len(out))
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsTimestamps(c *check.C) {
|
||||
|
@ -129,9 +120,6 @@ func (s *DockerSuite) TestLogsTimestamps(c *check.C) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsSeparateStderr(c *check.C) {
|
||||
|
@ -160,9 +148,6 @@ func (s *DockerSuite) TestLogsSeparateStderr(c *check.C) {
|
|||
if stderr != msg {
|
||||
c.Fatalf("Expected %v in stderr stream, got %v", msg, stderr)
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsStderrInStdout(c *check.C) {
|
||||
|
@ -191,9 +176,6 @@ func (s *DockerSuite) TestLogsStderrInStdout(c *check.C) {
|
|||
if stdout != msg {
|
||||
c.Fatalf("Expected %v in stdout stream, got %v", msg, stdout)
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsTail(c *check.C) {
|
||||
|
@ -243,8 +225,6 @@ func (s *DockerSuite) TestLogsTail(c *check.C) {
|
|||
if len(lines) != testLen+1 {
|
||||
c.Fatalf("Expected log %d lines, received %d\n", testLen+1, len(lines))
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsFollowStopped(c *check.C) {
|
||||
|
@ -275,8 +255,6 @@ func (s *DockerSuite) TestLogsFollowStopped(c *check.C) {
|
|||
case <-time.After(1 * time.Second):
|
||||
c.Fatal("Following logs is hanged")
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestLogsSince(c *check.C) {
|
||||
|
|
|
@ -35,9 +35,6 @@ func (s *DockerSuite) TestRmiWithContainerFails(c *check.C) {
|
|||
if !strings.Contains(images, "busybox") {
|
||||
c.Fatalf("The name 'busybox' should not have been removed from images: %q", images)
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
}
|
||||
|
||||
func (s *DockerSuite) TestRmiTag(c *check.C) {
|
||||
|
|
|
@ -120,10 +120,6 @@ func (s *DockerSuite) TestRunEchoNamedContainer(c *check.C) {
|
|||
if out != "test\n" {
|
||||
c.Errorf("container should've printed 'test'")
|
||||
}
|
||||
|
||||
if err := deleteContainer("testfoonamedcontainer"); err != nil {
|
||||
c.Errorf("failed to remove the named container: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
// docker run should not leak file descriptors
|
||||
|
@ -2534,9 +2530,6 @@ func (s *DockerSuite) TestRunAllowPortRangeThroughExpose(c *check.C) {
|
|||
c.Fatalf("Port is not mapped for the port %d", port)
|
||||
}
|
||||
}
|
||||
if err := deleteContainer(id); err != nil {
|
||||
c.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
||||
// test docker run expose a invalid port
|
||||
|
|
|
@ -54,8 +54,6 @@ func (s *DockerSuite) TestTopNonPrivileged(c *check.C) {
|
|||
c.Fatalf("failed to kill container: %s, %v", out, err)
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
if !strings.Contains(out1, "top") && !strings.Contains(out2, "top") {
|
||||
c.Fatal("top should've listed `top` in the process list, but failed twice")
|
||||
} else if !strings.Contains(out1, "top") {
|
||||
|
@ -92,8 +90,6 @@ func (s *DockerSuite) TestTopPrivileged(c *check.C) {
|
|||
c.Fatalf("failed to kill container: %s, %v", out, err)
|
||||
}
|
||||
|
||||
deleteContainer(cleanedContainerID)
|
||||
|
||||
if !strings.Contains(out1, "top") && !strings.Contains(out2, "top") {
|
||||
c.Fatal("top should've listed `top` in the process list, but failed twice")
|
||||
} else if !strings.Contains(out1, "top") {
|
||||
|
|
Loading…
Reference in a new issue