Skip to content

Latest commit

 

History

History
87 lines (57 loc) · 4.06 KB

File metadata and controls

87 lines (57 loc) · 4.06 KB

Node E2E Tests

This directory contains OpenShift end-to-end tests for node-related features.

Test Suites

Suite: openshift/disruptive-longrunning

  • kubeletconfig_features.go - Tests applying KubeletConfig to custom machine config pools, requires node reboots
  • kubelet_secret_pulled_images.go - Tests kubelet credential verification for image pulls (KubeletEnsureSecretPulledImages feature gate). Covers multi-tenancy isolation, credential rotation, ImagePullPolicy behavior, credential verification policy (NeverVerify/AlwaysVerify), and registry availability scenarios. Requires TechPreviewNoUpgrade or CustomNoUpgrade FeatureSet.
  • node_e2e/image_registry_config.go - Container registry config change (OCP-44820) - Verifies search registry update triggers MCO rollout and lands on nodes [Disruptive]
  • node_e2e/image_signature.go - Image signature verification - Verifies image signature verification for Red Hat Container Registries [Disruptive][Serial][OTP]

Suite: openshift/usernamespace

  • nested_container.go - Tests running nested containers (podman-in-pod) with user namespaces and nested-container SCC

Default Suite

  • dra.go - Tests that DRA (Dynamic Resource Allocation) v1 API is available and beta/alpha APIs are disabled
  • image_volume.go - Tests mounting container images as volumes in pods, including subPath and error handling
  • node_swap.go - Tests default kubelet swap settings (failSwapOn and swapBehavior) and rejection of user overrides
  • zstd_chunked.go - Tests building and running images with zstd:chunked compression format

Directory Structure

Test Files

  • All *.go files in the root directory are Ginkgo-based test suites
  • Each file focuses on a specific node feature

Utility Files

  • node_utils.go - Shared helper functions for node selection and kubelet configuration retrieval

Test Data

Test fixtures are referenced via exutil.FixturePath from:

  • testdata/node/machineconfigpool/ - Machine config pool fixtures
  • testdata/node/kubeletconfig/ - Kubelet config fixtures
  • testdata/node/zstd-chunked/, testdata/node/nested_container/ - Custom build fixtures

Running Tests

Running Long-Running Disruptive Tests

The openshift/disruptive-longrunning suite is a general-purpose suite for long-running disruptive tests across all teams. Node team tests are tagged with [sig-node] to identify them.

To run the entire long-running disruptive test suite on a cluster manually:

./openshift-tests run "openshift/disruptive-longrunning" --cluster-stability=Disruptive

To run only node-specific long-running disruptive tests:

./openshift-tests run "openshift/disruptive-longrunning" --dry-run | grep "\[sig-node\]" | ./openshift-tests run -f - --cluster-stability=Disruptive

Running User Namespace Tests

./openshift-tests run "openshift/usernamespace"

Prerequisites

  • Make sure to set oc binary to match the cluster version
  • Make sure to set the kubeconfig to point to a live OCP cluster

Submitting PRs

Adding Tests to openshift/disruptive-longrunning

Before submitting a PR that adds a test to the openshift/disruptive-longrunning suite, run the following payload job and include the results in your PR:

/payload-job periodic-ci-openshift-release-main-nightly-4.22-e2e-aws-disruptive-longrunning

Useful links for periodic-ci-openshift-release-main-nightly-4.22-e2e-aws-disruptive-longrunning:

Important Notes

  • Note that dry-run option won't list the test as it does not connect to a live cluster
  • Run make update if the test data is changed