Merge pull request #6352 from piosz/api

Removed PodStatus.Host
This commit is contained in:
Brian Grant
2015-04-02 13:16:24 -07:00
31 changed files with 149 additions and 199 deletions

View File

@@ -150,7 +150,7 @@ func RunRC(c *client.Client, name string, ns, image string, replicas int) {
if p.Status.Phase == api.PodRunning {
current++
} else if p.Status.Phase == api.PodPending {
if p.Status.Host == "" {
if p.Spec.Host == "" {
waiting++
} else {
pending++

View File

@@ -337,7 +337,7 @@ func testContainerOutputInNamespace(ns, scenarioName string, c *client.Client, p
}
By(fmt.Sprintf("Trying to get logs from host %s pod %s container %s: %v",
podStatus.Status.Host, podStatus.Name, containerName, err))
podStatus.Spec.Host, podStatus.Name, containerName, err))
var logs []byte
start := time.Now()
@@ -346,7 +346,7 @@ func testContainerOutputInNamespace(ns, scenarioName string, c *client.Client, p
logs, err = c.Get().
Prefix("proxy").
Resource("minions").
Name(podStatus.Status.Host).
Name(podStatus.Spec.Host).
Suffix("containerLogs", ns, podStatus.Name, containerName).
Do().
Raw()
@@ -354,7 +354,7 @@ func testContainerOutputInNamespace(ns, scenarioName string, c *client.Client, p
By(fmt.Sprintf("pod logs:%v\n", string(logs)))
if strings.Contains(string(logs), "Internal Error") {
By(fmt.Sprintf("Failed to get logs from host %q pod %q container %q: %v",
podStatus.Status.Host, podStatus.Name, containerName, string(logs)))
podStatus.Spec.Host, podStatus.Name, containerName, string(logs)))
time.Sleep(5 * time.Second)
continue
}

View File

@@ -127,7 +127,7 @@ func TestClient(t *testing.T) {
if actual.Name != got.Name {
t.Errorf("expected pod %#v, got %#v", got, actual)
}
if actual.Status.Host != "" {
if actual.Spec.Host != "" {
t.Errorf("expected pod to be unscheduled, got %#v", actual)
}
}