mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-02 16:29:21 +00:00
Add a test for important URLs on the apiserver.
This commit is contained in:
parent
203e76020e
commit
d43343db5e
@ -175,7 +175,11 @@ func TestPodUpdate(c *client.Client) bool {
|
|||||||
func TestImportantURLs(c *client.Client) bool {
|
func TestImportantURLs(c *client.Client) bool {
|
||||||
tests := []struct {
|
tests := []struct {
|
||||||
path string
|
path string
|
||||||
}{}
|
}{
|
||||||
|
{path: "/validate"},
|
||||||
|
{path: "/healthz"},
|
||||||
|
// TODO: test proxy links here
|
||||||
|
}
|
||||||
ok := true
|
ok := true
|
||||||
for _, test := range tests {
|
for _, test := range tests {
|
||||||
glog.Infof("testing: %s", test.path)
|
glog.Infof("testing: %s", test.path)
|
||||||
@ -183,10 +187,10 @@ func TestImportantURLs(c *client.Client) bool {
|
|||||||
AbsPath(test.path).
|
AbsPath(test.path).
|
||||||
Do().
|
Do().
|
||||||
Raw()
|
Raw()
|
||||||
}
|
if err != nil {
|
||||||
if err != nil {
|
glog.Errorf("Failed: %v\nBody: %s", err, string(data))
|
||||||
glog.Errorf("Failed: %v\nBody: %s", err, string(data))
|
ok = false
|
||||||
ok := false
|
}
|
||||||
}
|
}
|
||||||
return ok
|
return ok
|
||||||
}
|
}
|
||||||
@ -288,6 +292,7 @@ func main() {
|
|||||||
tests := []func(c *client.Client) bool{
|
tests := []func(c *client.Client) bool{
|
||||||
TestKubernetesROService,
|
TestKubernetesROService,
|
||||||
TestKubeletSendsEvent,
|
TestKubeletSendsEvent,
|
||||||
|
TestImportantURLs,
|
||||||
// TODO(brendandburns): fix this test and re-add it: TestPodUpdate,
|
// TODO(brendandburns): fix this test and re-add it: TestPodUpdate,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user