test: make test cases unique and test de-duplication
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Used by CI to test get-images-from-files action (K8s manifest, registry refs only)
|
||||
# Used by CI to test get-images-from-files action (K8s, distinct from Dockerfile)
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
@@ -9,12 +9,11 @@ spec:
|
||||
spec:
|
||||
containers:
|
||||
- name: app
|
||||
image: example.com/library/app:1.25-alpine
|
||||
- name: sidecar
|
||||
image: example.com/library/redis:7-alpine
|
||||
- name: distroless
|
||||
# Registry with tag (K8s)
|
||||
image: example.com/library/app:v2
|
||||
- name: shared
|
||||
# Same ref as in test.Dockerfile — tests deduplication
|
||||
image: example.com/distroless/static:nonroot
|
||||
- name: by-digest
|
||||
image: example.com/library/alpine@sha256:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef
|
||||
- name: fqdn-digest
|
||||
image: example.com/myproject/myimg@sha256:abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcd
|
||||
# Registry with digest (K8s)
|
||||
image: example.com/myproject/helper@sha256:bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
# Used by CI to test get-images-from-files action (varied image formats, registry refs only)
|
||||
# Short repo:tag (ignored by design; only registry refs are extracted)
|
||||
FROM nginx:3.19
|
||||
# Fully qualified with host and tag
|
||||
FROM example.com/library/nginx:latest
|
||||
# Registry path with tag
|
||||
# Used by CI to test get-images-from-files action (registry refs only, distinct from K8s)
|
||||
# Registry with tag (Dockerfile)
|
||||
FROM example.com/library/nginx:v1
|
||||
# Registry path with tag — shared with K8s to test deduplication
|
||||
FROM example.com/distroless/static:nonroot
|
||||
# With digest only but no registry (ignored)
|
||||
# Registry with digest (Dockerfile)
|
||||
FROM example.com/library/base@sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
|
||||
|
||||
# Ignored tags
|
||||
## Short repo:tag (ignored by design; only registry refs are extracted)
|
||||
FROM nginx:3.19
|
||||
## With digest only but no registry (ignored)
|
||||
FROM nginx@sha256:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef
|
||||
# Fully qualified with digest
|
||||
FROM example.com/distroless/static@sha256:abcdef1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcd
|
||||
|
||||
Reference in New Issue
Block a user