test(ingress): align assertions with the release name and namespace
The suite header was changed to the release `gitea-unittests` in the namespace `testing`, but the assertions still expected the previous `gitea-unittest` and `gitea-debug`. That made four cases fail on the rendered resource name, the `app.kubernetes.io/instance` label and the backend Service name. Renovate comments had additionally been copied into the expected `app.kubernetes.io/version` and `version` label values. They only matched by accident, because YAML strips the trailing comment from an unquoted scalar. Removing them keeps the assertions honest about what is actually compared. Co-authored-by: Copilot <copilot@github.com>
This commit is contained in:
@@ -1,9 +1,9 @@
|
|||||||
suite: Test ingress.yaml
|
|
||||||
chart:
|
chart:
|
||||||
appVersion: 1.27.3
|
appVersion: 1.27.3
|
||||||
release:
|
release:
|
||||||
name: gitea-unittest
|
name: gitea-unittests
|
||||||
namespace: gitea-debug
|
namespace: testing
|
||||||
|
suite: Test ingress.yaml
|
||||||
templates:
|
templates:
|
||||||
- templates/gitea/ingress.yaml
|
- templates/gitea/ingress.yaml
|
||||||
tests:
|
tests:
|
||||||
@@ -41,15 +41,15 @@ tests:
|
|||||||
- containsDocument:
|
- containsDocument:
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
name: gitea-unittest
|
name: gitea-unittests
|
||||||
namespace: gitea-debug
|
namespace: testing
|
||||||
- notExists:
|
- notExists:
|
||||||
path: metadata.annotations
|
path: metadata.annotations
|
||||||
- isSubset:
|
- isSubset:
|
||||||
path: metadata.labels
|
path: metadata.labels
|
||||||
content:
|
content:
|
||||||
app: gitea
|
app: gitea
|
||||||
app.kubernetes.io/instance: gitea-unittest
|
app.kubernetes.io/instance: gitea-unittests
|
||||||
app.kubernetes.io/managed-by: Helm
|
app.kubernetes.io/managed-by: Helm
|
||||||
app.kubernetes.io/name: gitea
|
app.kubernetes.io/name: gitea
|
||||||
app.kubernetes.io/version: 1.27.3
|
app.kubernetes.io/version: 1.27.3
|
||||||
@@ -66,7 +66,7 @@ tests:
|
|||||||
paths:
|
paths:
|
||||||
- backend:
|
- backend:
|
||||||
service:
|
service:
|
||||||
name: gitea-unittest-http
|
name: gitea-unittests-http
|
||||||
port:
|
port:
|
||||||
number: 3000
|
number: 3000
|
||||||
path: /
|
path: /
|
||||||
@@ -101,8 +101,8 @@ tests:
|
|||||||
- containsDocument:
|
- containsDocument:
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
name: gitea-unittest
|
name: gitea-unittests
|
||||||
namespace: gitea-debug
|
namespace: testing
|
||||||
- contains:
|
- contains:
|
||||||
path: spec.rules
|
path: spec.rules
|
||||||
content:
|
content:
|
||||||
@@ -111,7 +111,7 @@ tests:
|
|||||||
paths:
|
paths:
|
||||||
- backend:
|
- backend:
|
||||||
service:
|
service:
|
||||||
name: gitea-unittest-http
|
name: gitea-unittests-http
|
||||||
port:
|
port:
|
||||||
number: 32000
|
number: 32000
|
||||||
path: /
|
path: /
|
||||||
@@ -131,8 +131,8 @@ tests:
|
|||||||
- containsDocument:
|
- containsDocument:
|
||||||
kind: Ingress
|
kind: Ingress
|
||||||
apiVersion: networking.k8s.io/v1
|
apiVersion: networking.k8s.io/v1
|
||||||
name: gitea-unittest
|
name: gitea-unittests
|
||||||
namespace: gitea-debug
|
namespace: testing
|
||||||
- isSubset:
|
- isSubset:
|
||||||
path: metadata.annotations
|
path: metadata.annotations
|
||||||
content:
|
content:
|
||||||
|
|||||||
Reference in New Issue
Block a user