TerraTest: Test a Kubernetes deployment and service

Bruno Delb
Open DevOps Academy
7 min readApr 7, 2022

--

In this story, we will see how to test a Kubernetes deployment and service. For that, we will use TerraTest.

Create the deployment and service manifests

Now, we will create the deployment and the service that we want to test. In first, let’s create a deployment manifest deploy.yaml:

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deploy
spec:
selector:
matchLabels:
app: nginx
replicas: 1
template:
metadata:
labels…

--

--

Blockchains, DevOps, Agile Coaching, development, testing, Cloud, Management 3.0, ITIL. It defines me.