cloud-ark / kubeplus

Kubernetes Operator for multi-instance multi-tenancy
https://cloudark.io/
Apache License 2.0
662 stars 82 forks source link

Add test cases to verify Namespace handling #1224

Closed devdattakulkarni closed 6 months ago

devdattakulkarni commented 7 months ago

The basic design of KubePlus is that it will create an application instance (Helm release) in a new Namespace.

Nuanced aspects of this design should be covered with test cases.

  1. What happens if the underlying Helm chart defines a Namespace object? Is such a Helm chart rejected at the time of CRD registration?
  2. What happens if KubePlus is running in the non-default Namespace? Per an error message here, it seems that KubePlus will create new Namespaces if KubePlus itself is running in the default Namespace.
devdattakulkarni commented 6 months ago
  1. We have a test case already to cover this situation: https://github.com/cloud-ark/kubeplus/blob/master/tests/tests.py#L41

  2. This was tested - It does not matter what Namespace KubePlus is running in. Each application instance will be created in its own Namespace.