Fix tests that assume core clients use JSON

Signed-off-by: Monis Khan <mok@microsoft.com>
This commit is contained in:
Monis Khan
2024-08-19 10:38:16 -04:00
parent 032e7f1556
commit 6595fa4026
4 changed files with 11 additions and 7 deletions

View File

@@ -375,7 +375,7 @@ func TestCreatePodsWithGenerateName(t *testing.T) {
}
testServer := httptest.NewServer(&fakeHandler)
defer testServer.Close()
clientset := clientset.NewForConfigOrDie(&restclient.Config{Host: testServer.URL, ContentConfig: restclient.ContentConfig{GroupVersion: &schema.GroupVersion{Group: "", Version: "v1"}}})
clientset := clientset.NewForConfigOrDie(&restclient.Config{Host: testServer.URL, ContentConfig: restclient.ContentConfig{GroupVersion: &schema.GroupVersion{Group: "", Version: "v1"}, ContentType: runtime.ContentTypeJSON}})
podControl := RealPodControl{
KubeClient: clientset,