feat(common)!: Release common-3.0.0 (#284)

This commit is contained in:
Bernd Schorgers 2024-03-11 10:28:52 +01:00 committed by GitHub
parent a27c4f6124
commit 3981facca6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 124 additions and 116 deletions

View file

@ -44,6 +44,7 @@ tests:
- it: multiple ingress should pass
values:
- ../_values/service_main_default.yaml
- ../_values/ingress_main_default_hosts.yaml
set:
ingress.test:
@ -52,23 +53,27 @@ tests:
paths:
- path: /
service:
name: main
identifier: main
port: http
asserts:
- hasDocuments:
count: 3
count: 4
- documentIndex: 0
not: true
isKind:
of: Ingress
- documentIndex: &FirstIngressDocument 1
- documentIndex: 1
not: true
isKind:
of: Ingress
- documentIndex: &FirstIngressDocument 2
isKind:
of: Ingress
- documentIndex: *FirstIngressDocument
equal:
path: metadata.name
value: RELEASE-NAME-main
- documentIndex: &SecondIngressDocument 2
- documentIndex: &SecondIngressDocument 3
isKind:
of: Ingress
- documentIndex: *SecondIngressDocument
@ -87,7 +92,7 @@ tests:
paths:
- path: /
service:
name: main
identifier: main
port: http
asserts:
- hasDocuments:

View file

@ -52,6 +52,29 @@ tests:
port:
number: 1234
- it: custom service reference with template should pass
set:
ingress.main:
hosts:
- host: chart-test.local
paths:
- path: /
service:
name: "{{ .Release.Name }}"
port: 1234
asserts:
- documentIndex: &IngressDocument 1
isKind:
of: Ingress
- documentIndex: *IngressDocument
equal:
path: spec.rules[0].http.paths[0].backend
value:
service:
name: RELEASE-NAME
port:
number: 1234
- it: multiple hosts with port name references should pass
set:
service:
@ -72,14 +95,14 @@ tests:
- path: /
pathType: Prefix
service:
name: main
identifier: main
port: http
- host: http2.chart-test.local
paths:
- path: /
pathType: Prefix
service:
name: main
identifier: main
port: http2
asserts:
- documentIndex: &IngressDocument 2

View file

@ -6,11 +6,12 @@ templates:
values:
- ../_values/ingress_main_default_hosts.yaml
- ../_values/service_main_default.yaml
tests:
- it: default should pass
asserts:
- documentIndex: &IngressDocument 1
- documentIndex: &IngressDocument 2
isKind:
of: Ingress
- documentIndex: *IngressDocument
@ -30,9 +31,9 @@ tests:
paths:
- path: /test
service:
name: main
identifier: main
asserts:
- documentIndex: &IngressDocument 1
- documentIndex: &IngressDocument 2
isKind:
of: Ingress
- documentIndex: *IngressDocument
@ -52,10 +53,10 @@ tests:
paths:
- path: /
service:
name: main
identifier: main
port: http
asserts:
- documentIndex: &IngressDocument 1
- documentIndex: &IngressDocument 2
isKind:
of: Ingress
- documentIndex: *IngressDocument
@ -71,9 +72,9 @@ tests:
paths:
- path: "/{{ .Release.Name }}.path"
service:
name: main
identifier: main
asserts:
- documentIndex: &IngressDocument 1
- documentIndex: &IngressDocument 2
isKind:
of: Ingress
- documentIndex: *IngressDocument
@ -86,7 +87,7 @@ tests:
ingress.main:
defaultBackend: test
asserts:
- documentIndex: &IngressDocument 1
- documentIndex: &IngressDocument 2
isKind:
of: Ingress
- documentIndex: *IngressDocument