mirror of
https://github.com/kubernetes-sigs/kustomize.git
synced 2026-06-12 01:14:22 +00:00
add regression coverage
This commit is contained in:
@@ -34,6 +34,7 @@ import (
|
|||||||
func setupTest(t *testing.T) loader.Loader {
|
func setupTest(t *testing.T) loader.Loader {
|
||||||
kustomizationContent := []byte(`
|
kustomizationContent := []byte(`
|
||||||
namePrefix: foo-
|
namePrefix: foo-
|
||||||
|
namespace: foo
|
||||||
commonLabels:
|
commonLabels:
|
||||||
app: nginx
|
app: nginx
|
||||||
commonAnnotations:
|
commonAnnotations:
|
||||||
@@ -83,6 +84,7 @@ func TestResources(t *testing.T) {
|
|||||||
"kind": "Deployment",
|
"kind": "Deployment",
|
||||||
"metadata": map[string]interface{}{
|
"metadata": map[string]interface{}{
|
||||||
"name": "foo-dply1",
|
"name": "foo-dply1",
|
||||||
|
"namespace": "foo",
|
||||||
"labels": map[string]interface{}{
|
"labels": map[string]interface{}{
|
||||||
"app": "nginx",
|
"app": "nginx",
|
||||||
},
|
},
|
||||||
@@ -116,6 +118,7 @@ func TestResources(t *testing.T) {
|
|||||||
"kind": "ConfigMap",
|
"kind": "ConfigMap",
|
||||||
"metadata": map[string]interface{}{
|
"metadata": map[string]interface{}{
|
||||||
"name": "foo-literalConfigMap-mc92bgcbh5",
|
"name": "foo-literalConfigMap-mc92bgcbh5",
|
||||||
|
"namespace": "foo",
|
||||||
"labels": map[string]interface{}{
|
"labels": map[string]interface{}{
|
||||||
"app": "nginx",
|
"app": "nginx",
|
||||||
},
|
},
|
||||||
@@ -137,6 +140,7 @@ func TestResources(t *testing.T) {
|
|||||||
"kind": "Secret",
|
"kind": "Secret",
|
||||||
"metadata": map[string]interface{}{
|
"metadata": map[string]interface{}{
|
||||||
"name": "foo-secret-877fcfhgt5",
|
"name": "foo-secret-877fcfhgt5",
|
||||||
|
"namespace": "foo",
|
||||||
"labels": map[string]interface{}{
|
"labels": map[string]interface{}{
|
||||||
"app": "nginx",
|
"app": "nginx",
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user