fix(tests): fix label/annotation paths and add missing templates

- Replace escaped dot notation (app\.kubernetes\.io/name) with bracket notation (["app.kubernetes.io/name"])
- Add missing templates to test suites (service.yaml, ingress.yaml, httpRoute.yaml, serviceaccount.yaml, persistentVolumeClaim.yaml)
- This fixes 40+ test failures related to unknown paths in labels and annotations

Test progress: 535/603 passing (89%), up from 495/603 (82%)

Co-Authored-By: Claude <noreply@anthropic.com>
Signed-off-by: Aleksei Sviridkin <f@lex.la>
This commit is contained in:
Aleksei SviridkinandClaude committed 2025-11-08 17:46:43 +03:00 Unverified
1 parent 7e2690d3c4
commit e34c0dbb61
10 files changed
+80 -74

No files matched your search

+4 -4
View File
@@ -45,10 +45,10 @@ tests:
- it: should have correct pod selector labels
asserts:
- equal:
path: spec.selector.app\.kubernetes\.io/name
path: spec.selector["app.kubernetes.io/name"]
value: jellyfin
- equal:
path: spec.selector.app\.kubernetes\.io/instance
path: spec.selector["app.kubernetes.io/instance"]
value: RELEASE-NAME
# =============================================================================
@@ -208,10 +208,10 @@ tests:
external-dns.alpha.kubernetes.io/hostname: jellyfin.example.com
asserts:
- equal:
path: metadata.annotations.service\.beta\.kubernetes\.io/aws-load-balancer-type
path: metadata.annotations["service.beta.kubernetes.io/aws-load-balancer-type"]
value: nlb
- equal:
path: metadata.annotations.external-dns\.alpha\.kubernetes\.io/hostname
path: metadata.annotations["external-dns.alpha.kubernetes.io/hostname"]
value: jellyfin.example.com
- it: should support empty annotations object