Browse Source

Merge pull request #28800 from lixiaobing10051267/masterState

Fix some output information for container test
Justin Cormack 8 years ago
parent
commit
0f79746f3d
2 changed files with 3 additions and 3 deletions
  1. 2 2
      container/memory_store_test.go
  2. 1 1
      container/state_test.go

+ 2 - 2
container/memory_store_test.go

@@ -62,7 +62,7 @@ func TestListContainers(t *testing.T) {
 		t.Fatalf("expected list size 2, got %v", len(list))
 		t.Fatalf("expected list size 2, got %v", len(list))
 	}
 	}
 	if list[0].ID != "id2" {
 	if list[0].ID != "id2" {
-		t.Fatalf("expected older container to be first, got %v", list[0].ID)
+		t.Fatalf("expected id2, got %v", list[0].ID)
 	}
 	}
 }
 }
 
 
@@ -101,6 +101,6 @@ func TestApplyAllContainer(t *testing.T) {
 		t.Fatal("expected container to not be nil")
 		t.Fatal("expected container to not be nil")
 	}
 	}
 	if cont.ID != "newID" {
 	if cont.ID != "newID" {
-		t.Fatalf("expected newID, got %v", cont)
+		t.Fatalf("expected newID, got %v", cont.ID)
 	}
 	}
 }
 }

+ 1 - 1
container/state_test.go

@@ -105,7 +105,7 @@ func TestStateTimeoutWait(t *testing.T) {
 	}()
 	}()
 	select {
 	select {
 	case <-time.After(200 * time.Millisecond):
 	case <-time.After(200 * time.Millisecond):
-		t.Fatal("Stop callback doesn't fire in 100 milliseconds")
+		t.Fatal("Stop callback doesn't fire in 200 milliseconds")
 	case <-stopped:
 	case <-stopped:
 		t.Log("Stop callback fired")
 		t.Log("Stop callback fired")
 	}
 	}