This commit is contained in:
Mike Danese
2020-01-27 18:19:44 -08:00
parent 59e757afef
commit d55d6175f8
105 changed files with 415 additions and 325 deletions

View File

@@ -17,6 +17,7 @@ limitations under the License.
package apiserver
import (
"context"
"encoding/json"
"fmt"
"io/ioutil"
@@ -228,7 +229,7 @@ func waitForWardleRunning(t *testing.T, wardleToKASKubeConfig *rest.Config, ward
return false, nil
}
healthStatus := 0
result := wardleClient.Discovery().RESTClient().Get().AbsPath("/healthz").Do().StatusCode(&healthStatus)
result := wardleClient.Discovery().RESTClient().Get().AbsPath("/healthz").Do(context.TODO()).StatusCode(&healthStatus)
lastHealthContent, lastHealthErr = result.Raw()
if healthStatus != http.StatusOK {
return false, nil
@@ -345,7 +346,7 @@ func createKubeConfig(clientCfg *rest.Config) *clientcmdapi.Config {
}
func readResponse(client rest.Interface, location string) ([]byte, error) {
return client.Get().AbsPath(location).DoRaw()
return client.Get().AbsPath(location).DoRaw(context.TODO())
}
func testAPIGroupList(t *testing.T, client rest.Interface) {