Skip to content

Commit

Permalink
Debuging deletion of the healthcheck namespace
Browse files Browse the repository at this point in the history
Signed-off-by: Mohammed Boukhalfa <[email protected]>
  • Loading branch information
mboukhalfa committed Apr 30, 2024
1 parent c7d3e8f commit 8012ca1
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/e2e/md_remediations_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,12 @@ import (
"os/exec"
"path/filepath"
"strings"
"time"

bmov1alpha1 "github.com/metal3-io/baremetal-operator/apis/metal3.io/v1alpha1"
. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
"k8s.io/utils/ptr"
bmov1alpha1 "github.com/metal3-io/baremetal-operator/apis/metal3.io/v1alpha1"
capi_e2e "sigs.k8s.io/cluster-api/test/e2e"
"sigs.k8s.io/controller-runtime/pkg/client"
)
Expand All @@ -37,6 +38,7 @@ var _ = Describe("When testing MachineDeployment remediation [healthcheck] [reme
AfterEach(func() {
// Recreate bmh that was used in capi namespace in metal3
//#nosec G204 -- We need to pass in the file name here.
time.Sleep(80 * time.Minute)
cmd := exec.Command("bash", "-c", "kubectl apply -f bmhosts_crs.yaml -n metal3")
cmd.Dir = workDir
output, err := cmd.CombinedOutput()
Expand All @@ -48,7 +50,7 @@ var _ = Describe("When testing MachineDeployment remediation [healthcheck] [reme
WaitForNumBmhInState(ctx, bmov1alpha1.StateAvailable, WaitForNumInput{
Client: bootstrapClient,
Options: []client.ListOption{client.InNamespace(namespace)},
Replicas: 5,
Replicas: 4,
Intervals: e2eConfig.GetIntervals(specName, "wait-bmh-available"),
})
ListBareMetalHosts(ctx, bootstrapClient, client.InNamespace(namespace))
Expand Down

0 comments on commit 8012ca1

Please sign in to comment.