kubernetes/test/e2e/dra
Kubernetes Prow Robot eeb690e1f3
Merge pull request #137597 from pohly/dra-extended-resource-version-skew
DRA: re-enable extended resource tests for version skew testing
2026-03-13 21:09:36 +05:30
..
test-driver DRA device taints: graduate to beta 2026-03-12 18:26:02 +01:00
utils Merge pull request #137170 from pohly/dra-device-taints-beta 2026-03-13 00:13:38 +05:30
deploy_device_plugin.go DRA: e2e: refactor device plugin deployment 2026-02-11 16:11:24 +02:00
dra.go Merge pull request #137597 from pohly/dra-extended-resource-version-skew 2026-03-13 21:09:36 +05:30
kind.yaml E2E: check system logs for DATA RACE reports 2026-01-16 15:14:54 +01:00
OWNERS add SIG-Node approvers to DRA dirs 2026-01-13 11:52:29 +02:00
README.md Make golang::setup-env turn on workspaces 2024-02-29 22:07:42 -08:00

Overview

The tests in this directory cover dynamic resource allocation support in Kubernetes. They do not test the correct behavior of arbitrary dynamic resource allocation drivers.

If such a driver is needed, then the in-tree test/e2e/dra/test-driver is used, with a slight twist: instead of deploying that driver directly in the cluster, the necessary sockets for interaction with kubelet (registration and dynamic resource allocation) get proxied into the e2e.test binary. This reuses the work done for CSI mock testing. The advantage is that no separate images are needed for the test driver and that the e2e test has full control over all gRPC calls, in case that it needs that for operations like error injection or checking calls.

Cluster setup preparation

The container runtime must support CDI. CRI-O supports CDI starting from release 1.23, Containerd supports CDI starting from release 1.7. To bring up a Kind cluster with Containerd, two things are needed:

NB: Kind switched to use worker-node base image with Containerd 1.7 by default starting from release 0.20, build kind from latest main branch sources or use Kind release binary 0.20 or later.

Build kind node image

After building Kubernetes, in Kubernetes source code tree build new node image:

$ kind build node-image --image dra/node:latest $(pwd)

Bring up a Kind cluster

$ kind create cluster --config test/e2e/dra/kind.yaml --image dra/node:latest

Run tests

  • Build ginkgo
$ make ginkgo
  • Run e2e tests for the Dynamic Resource Allocation feature:
$ KUBECONFIG=~/.kube/config _output/bin/ginkgo -p -v -focus=Feature:DynamicResourceAllocation ./test/e2e