mirror of
https://github.com/actions/actions-runner-controller.git
synced 2026-01-18 01:33:32 +08:00
50 lines
1.4 KiB
YAML
50 lines
1.4 KiB
YAML
suite: "Test GitHub Secret Annotations"
|
|
templates:
|
|
- githubsecret.yaml
|
|
tests:
|
|
- it: should include global annotations
|
|
set:
|
|
scaleset.name: "test"
|
|
auth.url: "https://github.com/org"
|
|
auth.githubToken: "gh_token12345"
|
|
resource:
|
|
all:
|
|
metadata:
|
|
annotations:
|
|
a: "global"
|
|
shared: "global"
|
|
release:
|
|
name: "test-name"
|
|
namespace: "test-namespace"
|
|
asserts:
|
|
- equal:
|
|
path: metadata.annotations.a
|
|
value: "global"
|
|
- equal:
|
|
path: metadata.annotations.shared
|
|
value: "global"
|
|
|
|
- it: should drop actions.github.com annotations from global config
|
|
set:
|
|
scaleset.name: "test"
|
|
auth.url: "https://github.com/org"
|
|
auth.githubToken: "gh_token12345"
|
|
resource:
|
|
all:
|
|
metadata:
|
|
annotations:
|
|
ok: "ok"
|
|
actions.github.com/values-hash: "user-value"
|
|
actions.github.com/cleanup-something: "should-not-render"
|
|
release:
|
|
name: "test-name"
|
|
namespace: "test-namespace"
|
|
asserts:
|
|
- equal:
|
|
path: metadata.annotations.ok
|
|
value: "ok"
|
|
- notExists:
|
|
path: metadata.annotations["actions.github.com/values-hash"]
|
|
- notExists:
|
|
path: metadata.annotations["actions.github.com/cleanup-something"]
|