소스 검색

Use the first 12 characters of the ID to match the output of docker stats command

Signed-off-by: Corbin <corbin.coleman@docker.com>
Corbin 7 년 전
부모
커밋
8c10098ea5
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      integration-cli/docker_cli_stats_test.go

+ 1 - 1
integration-cli/docker_cli_stats_test.go

@@ -34,7 +34,7 @@ func (s *DockerSuite) TestStatsNoStream(c *check.C) {
 	select {
 	case outerr := <-ch:
 		c.Assert(outerr.err, checker.IsNil, check.Commentf("Error running stats: %v", outerr.err))
-		c.Assert(string(outerr.out), checker.Contains, id) //running container wasn't present in output
+		c.Assert(string(outerr.out), checker.Contains, id[:12]) //running container wasn't present in output
 	case <-time.After(3 * time.Second):
 		statsCmd.Process.Kill()
 		c.Fatalf("stats did not return immediately when not streaming")