kubewarden / capabilities-psp-policy

A Pod Security Policy that controls Container Capabilities
https://kubewarden.io
Apache License 2.0
5 stars 7 forks source link

test: Add e2e tests #36

Closed geeksambhu closed 1 year ago

geeksambhu commented 1 year ago

Description

Added e2e tests to cover the Pod Security policy scenarios These are the end-to-end scenarios covered:

Fix https://github.com/kubewarden/capabilities-psp-policy/issues/8

Test

To test this pull request, you can run the following commands:

make e2e-tests

Additional Information

Tradeoff

Potential improvement

Add more scenarios

viccuad commented 1 year ago

Many thanks folks for the review!

I agree with Flavio. @geeksambhu , can we reduce the content of the test_data jsons? It should be enough if they are pod requests, like this one for example, and also containing the relevant part of the pod spec for this policy. So, the spec.containers.securityContext.

geeksambhu commented 1 year ago

Hi @viccuad & @jvanz , I updated the content of test data. Please review