From 8461cde200bac8bfed5d5215b939cc1d8486aef6 Mon Sep 17 00:00:00 2001 From: Sebastian Malton Date: Mon, 1 May 2023 16:27:21 -0400 Subject: [PATCH] chore: Fix kube-api tests Signed-off-by: Sebastian Malton --- .../core/src/common/k8s-api/__tests__/kube-api.test.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/packages/core/src/common/k8s-api/__tests__/kube-api.test.ts b/packages/core/src/common/k8s-api/__tests__/kube-api.test.ts index 6e5c1f507a..39b778b020 100644 --- a/packages/core/src/common/k8s-api/__tests__/kube-api.test.ts +++ b/packages/core/src/common/k8s-api/__tests__/kube-api.test.ts @@ -467,7 +467,7 @@ describe("KubeApi", () => { }); it("should resolve the call with >=200 <300 http code", async () => { - await fetchMock.resolveSpecific( + void fetchMock.resolveSpecific( ["http://127.0.0.1:9999/api-kube/api/v1/namespaces/test/pods/foo/eviction"], createMockResponseFromString("http://127.0.0.1:9999/api-kube/api/v1/namespaces/test/pods/foo/eviction", JSON.stringify({ apiVersion: "policy/v1", @@ -481,7 +481,7 @@ describe("KubeApi", () => { }); it("should throw in case of error", async () => { - await fetchMock.resolveSpecific( + void fetchMock.resolveSpecific( ["http://127.0.0.1:9999/api-kube/api/v1/namespaces/test/pods/foo/eviction"], createMockResponseFromString("http://127.0.0.1:9999/api-kube/api/v1/namespaces/test/pods/foo/eviction", JSON.stringify({ apiVersion: "policy/v1", @@ -574,12 +574,6 @@ describe("KubeApi", () => { }); }); }); - - describe("when deleting by name and namespace", () => { - it("rejects request", async () => { - await expect(api.delete({ name: "foo", namespace: "test" })).rejects.toBeDefined(); - }); - }); }); describe("watching pods", () => {