Crate k8s_test_framework

source ·
Expand description

Kubernetes test framework.

The main goal of the design of this test framework is to wire kubernetes components testing through the same tools that are available to the developer as executable commands, rather than using a rust interface to talk to k8s cluster directly. This enables very trivial troubleshooting and allows us to use the same deployment mechanisms that we use for production - effectively giving us the opportunity to test e2e: not just the code layer, but also the deployment configuration.

Re-exports§

Modules§

Structs§

  • Manages commands for bringing up and shutting down resources on the cluster.
  • Keeps track of the continuously running kubectl port-forward command, exposing the API to terminate it when needed.
  • Keeps track of the command invocation, proving the interface to read the output and send a termination signal.

Functions§

  • A shared lock to use commonly among the tests. The goal is to guarantee that only one test is executing concurrently, since tests use a shared resource - a k8s cluster - and will conflict with each other unless they’re executing sequentially.