From c6dc0b5d629064cf8b0246e16c978a829e1b8715 Mon Sep 17 00:00:00 2001 From: "michal.gubricky" Date: Mon, 7 Oct 2024 14:00:47 +0200 Subject: [PATCH] Remove unused functions Signed-off-by: michal.gubricky --- .../scs-conformance-sonobuoy-plugin.yaml | 2 +- .../scs_0217_cluster_hardening_test.go | 17 ----------------- 2 files changed, 1 insertion(+), 18 deletions(-) diff --git a/Tests/kaas/kaas-sonobuoy-tests/scs-conformance-sonobuoy-plugin.yaml b/Tests/kaas/kaas-sonobuoy-tests/scs-conformance-sonobuoy-plugin.yaml index 48097d943..c81658325 100644 --- a/Tests/kaas/kaas-sonobuoy-tests/scs-conformance-sonobuoy-plugin.yaml +++ b/Tests/kaas/kaas-sonobuoy-tests/scs-conformance-sonobuoy-plugin.yaml @@ -7,7 +7,7 @@ spec: command: - bash args: ["-c","go tool test2json ./custom.test -test.v | tee ${SONOBUOY_RESULTS_DIR}/out.json ; echo ${SONOBUOY_RESULTS_DIR}/out.json > ${SONOBUOY_RESULTS_DIR}/done"] - image: ghcr.io/sovereigncloudstack/standards/scs-kaas-conformance:dev + image: registry.dnation.cloud/test-mg/scsconformance:dev #ghcr.io/sovereigncloudstack/standards/scs-kaas-conformance:dev env: - name: NS_PREFIX value: custom diff --git a/Tests/kaas/kaas-sonobuoy-tests/scs_k8s_conformance_tests/scs_0217_cluster_hardening_test.go b/Tests/kaas/kaas-sonobuoy-tests/scs_k8s_conformance_tests/scs_0217_cluster_hardening_test.go index bbeb7f5b9..160276ccd 100644 --- a/Tests/kaas/kaas-sonobuoy-tests/scs_k8s_conformance_tests/scs_0217_cluster_hardening_test.go +++ b/Tests/kaas/kaas-sonobuoy-tests/scs_k8s_conformance_tests/scs_0217_cluster_hardening_test.go @@ -549,23 +549,6 @@ func isPortSecuredWithHTTPS(ip string, port int32, timeout time.Duration) bool { return true } -// waitForDirectory waits for a directory to become available at a specified path. -func waitForDirectory(path string, timeout time.Duration) error { - start := time.Now() - for time.Since(start) < timeout { - if info, err := os.Stat(path); err == nil && info.IsDir() { - return nil - } - time.Sleep(5 * time.Second) - } - return fmt.Errorf("directory %s not found after %v", path, timeout) -} - -// isConfigzFile checks if a file is a configz.json file. -func isConfigzFile(fileName string) bool { - return fileName != "" && (fileName[0:8] == "configz-") -} - // readKubeletConfigFromFile reads and parses the Kubelet configuration from a file. func readKubeletConfigFromFile(path string) (*KubeletConfig, error) { fmt.Printf("Reading Kubelet config from file: %s\n", path)