GoogleCloudPlatform / marketplace-k8s-app-example

Apache License 2.0
23 stars 19 forks source link

Show how to convert Helm tests to deployer tests #60

Open deustis opened 6 years ago

deustis commented 6 years ago

Suggested by @moxious:

Helm has a built-in mechanism for tests: https://docs.helm.sh/developing_charts/#chart-tests

In short, the author of the chart adds additional pod definitions annotated with helm.sh/hook: test-success or helm.sh/hook: test-failure.

As a convention, these tests frequently live under a tests/ subdirectory: https://github.com/kubernetes/charts/tree/master/stable/wordpress/templates/tests

We should update the nginx example to show how to easily include tests in the main Chart, exclude them from the deployer, and included them in the tester.