Skip to content

test(e2e): port Kubernetes driver tests from e2e/rust to drivers/kubernetes #6213

In progress

Description

@matthewgrossman

User Story

As a maintainer retiring e2e/rust, I want the Kubernetes-only tests on testkit under tests/suites/drivers/kubernetes, so they run against tmachine k3s environments, and new Kubernetes tests have a testkit home instead of landing in e2e/rust.

Description

This is PR8 in the #5297 plan comment, which has the per-test table (actions, destinations, drops). Summary:

Legacy file Action Destination
shared_supervisor/mod.rs (helpers + 7 tests) port tests/support/kube (shared_supervisor module)
kubernetes_runtime_reconcile.rs port 1, drop 1 (D) drivers/kubernetes
user_namespaces.rs drop (D) —
credential_drivers.rs port drivers/kubernetes
workspace_namespace_managed.rs, workspace_namespace_operator.rs port, merge drivers/kubernetes (DNS-1123 name check → conformance if the server validates it)
kubernetes_shared_supervisor.rs, _ha.rs, _scaling.rs port, split drivers/kubernetes
kubernetes_shared_supervisor_spiffe.rs (+ node_local.rs) port (added after the inventory, #4732) drivers/kubernetes
kubernetes_tracing.rs port, with its Jaeger fixture (added after the inventory, #5517) drivers/kubernetes
kubernetes_corporate_proxy.rs split features/corporate-proxy (k3s row) + driver unit test
ephemeral_cleanup.rs Kubernetes half, additional_ca.rs Helm branch port drivers/kubernetes

kubernetes_ha_rebalancing.rs goes to tests/suites/destructive/kubernetes-ha with #5527 (decision G), not here.

Also move e2e/kubernetes/postgres-fixture.yaml under tests/ and update its readers (tmachine's k3s-ha installer and cache key, with-kube-gateway.sh, run-postgres-tests.sh, the helm-dev-environment skill).

Helpers and environment

  • tests/support/kube: a Rust kube client built from published variables, namespace and sandbox-resource lookups, a gateway_can RBAC check, port-forwarding, and the shared-supervisor helpers. Tests don't fall back to ambient KUBECONFIG (decision F).
  • Kubernetes rows publish OPENSHELL_TEST_KUBECONFIG and the test namespace (decision F), plus what the tests need (release, sandbox namespace, chart path, gateway replicas).
  • Any per-test timeouts or serial groups go through test(runner): add a per-row test timeout to runner rows #5295.

Context

Definition of Done

  • Every test in the PR8 table is ported, merged, split or dropped as listed.
  • Each new OPENSHELL_TEST_* variable is documented in the per-crate docs table.
  • The listed files are deleted, with every reference to them (OPENSHELL_E2E_KUBE_TEST tasks, wrapper scripts, nextest groups).
  • drivers/kubernetes has k3s and k3s-ha rows in .github/workflows/e2e-suites.yml.

Activity

  1. added
    topic:testing
    on Dec 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

topic:testing

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions