Skip to content

Commit bc020f4

Browse files
committed
Add README with info on tests
1 parent 0e365ee commit bc020f4

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

e2e/README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# End-to-end tests for konnectivity-network-proxy running in a KinD cluster
2+
3+
These e2e tests deploy the KNP agent and server to a local [KinD](https://kind.sigs.k8s.io/)
4+
cluster to verify their functionality.
5+
6+
These can be run automatically using `make e2e-test`.
7+
8+
## Setup in `main_test.go`
9+
10+
Before any of the actual tests are run, the `TestMain()` function
11+
in `main_test.go` performs the following set up steps:
12+
13+
- Spin up a new KinD cluster with the node image provided by the `-kind-image` flag.
14+
- Sideload the KNP agent and server images provided with `-agent-image` and `-server-image` into the cluster.
15+
- Deploy the necessary RBAC and service templates for both the KNP agent and server (see `renderAndApplyManifests`).
16+
17+
## The tests
18+
19+
### `static_count_test.go`
20+
21+
These tests deploy the KNP servers and agents to the previously created KinD cluster.
22+
After the deployments are up, the tests check that both the agent and server report
23+
the correct number of connections on their metrics endpoints.

0 commit comments

Comments
 (0)