Uploaded image for project: 'OpenShift Windows Containers'
  1. OpenShift Windows Containers
  2. WINC-1623

Implement NEW automated test for DaemonSet drain validation

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Done
    • Icon: Undefined Undefined
    • None
    • None
    • None
    • None
    • Quality / Stability / Reliability
    • False
    • Hide

      None

      Show
      None
    • False
    • 5
    • None
    • None
    • None

      Implement NEW standalone automated test in openshift-tests-private to validate DaemonSet drain handling during WMCO node reconfiguration.

      *Test ID*: OCP-87809 (Polarion test case created in WINC-1622)

      *Implementation*: Create new test case in test/extended/winc/winc.go - DO NOT extend existing tests.

      *DaemonSet deployment using Go string templates*:

      • Use oc.AsAdmin().Run("create") with proper Go string formatting
      • Namespace: openshift-winc-test
      • Image: mcr.microsoft.com/windows/nanoserver:ltsc2022
      • NodeSelector: kubernetes.io/os: windows
      • Tolerations: os=Windows:NoSchedule

      *Trigger node reconfiguration* (without full upgrade):

      • Option 1: Patch node version annotation to force WMCO reconciliation
      • Option 2: Patch windows-instances ConfigMap to trigger reconfiguration
      • Option 3: Scale WMCO deployment down/up to force node reprocessing

      *Key test validations*:

      RBAC permissions in test namespace:
      ```
      oc auth can-i get daemonsets.apps -n openshift-winc-test --as=system:serviceaccount:openshift-windows-machine-config-operator:windows-machine-config-operator
      oc auth can-i delete daemonsets.apps -n openshift-winc-test --as=system:serviceaccount:openshift-windows-machine-config-operator:windows-machine-config-operator
      oc auth can-i list daemonsets.apps -n openshift-winc-test --as=system:serviceaccount:openshift-windows-machine-config-operator:windows-machine-config-operator
      ```

      • DaemonSet status.numberReady matches Windows node count before trigger
      • Node drain succeeds (monitor WMCO logs for no permission errors)
      • DaemonSet status.numberReady matches Windows node count after reconfiguration

      *Files to modify*:

      • test/extended/winc/winc.go (new test case)

      *CI profiles*:

      • debug-winc-aws-ipi
      • debug-winc-gcp-ipi
      • debug-winc-azure-ipi
      • debug-winc-vsphere-ipi

              rrasouli Aharon Rasouli
              rrasouli Aharon Rasouli
              None
              None
              None
              None
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: