From 5ae184428f46c96afa3c1a86590718e1f21cd8cc Mon Sep 17 00:00:00 2001 From: Shunsuke Suzuki Date: Tue, 27 Aug 2024 09:08:56 +0900 Subject: [PATCH] ci: add testdata (#3067) * ci: add testdata * ci: move a test * ci: test * ci: enable checksum verification * fix: fix checksums of cosign --- .github/workflows/wc-integration-test.yaml | 7 +++++++ pkg/cosign/version.go | 10 +++++----- tests/3064/aqua.yaml | 14 ++++++++++++++ 3 files changed, 26 insertions(+), 5 deletions(-) create mode 100644 tests/3064/aqua.yaml diff --git a/.github/workflows/wc-integration-test.yaml b/.github/workflows/wc-integration-test.yaml index 3d4139de4..0d7b7d3cc 100644 --- a/.github/workflows/wc-integration-test.yaml +++ b/.github/workflows/wc-integration-test.yaml @@ -28,6 +28,7 @@ jobs: - run: go install ./cmd/aqua - run: echo "${XDG_DATA_HOME:-$HOME/.local/share}/aquaproj-aqua/bin" >> "$GITHUB_PATH" - run: aqua policy allow + - run: echo "standard,kubernetes-sigs/kind" | aqua g -f - env: GITHUB_TOKEN: ${{steps.token.outputs.token}} @@ -52,6 +53,12 @@ jobs: env: GITHUB_TOKEN: ${{steps.token.outputs.token}} + - name: Test checksum + run: aqua -c aqua.yaml i + working-directory: tests/3064 + env: + GITHUB_TOKEN: ${{github.token}} + - name: Test version_prefix run: aqua -c aqua.yaml g -i kubernetes-sigs/kustomize working-directory: tests/main diff --git a/pkg/cosign/version.go b/pkg/cosign/version.go index 4ad7a63a7..b0ea5bfbd 100644 --- a/pkg/cosign/version.go +++ b/pkg/cosign/version.go @@ -4,10 +4,10 @@ const Version = "v2.4.0" func Checksums() map[string]string { return map[string]string{ - "darwin/amd64": "0E5A77A86115E4C00BA4243DB01ABCEACB13CC06981C45E53EE71F2E1DB8CE25", - "darwin/arm64": "FCD310E64ECDDC1EAA13FE814AC1C9FC02F6F9EACD9A58480AB8160EB8CA381E", - "linux/amd64": "97A6A1E15668A75FC4FF7A4DC4CB2F098F929CBEA2F12FAA9DE31DB6B42B17D7", - "linux/arm64": "658087351E1D4F9C396B5F59EE5437461C06128F4CE80BA899CCAA1C0B6A8A62", - "windows/amd64": "9E9B71BD3FA2A6ABFA903B5F784D9CA0FBC29C563D2B084C1A82C593C2BAB001", + "darwin/amd64": "4D568E3BF56D254948A749D1442EEDB6DC624AF0A1ACEA082E260BA66B9FEB08", + "darwin/arm64": "779F57759A9863DACEA1256FA7F116319790DFCD4F9F8B33ABC30251B1F4A883", + "linux/amd64": "CD7636B3586A3BDAC2D9C8F3B421ED119EDCB20499107887FD929211110E8418", + "linux/arm64": "E9DB44C01057395230D0454144C676E7231BFF08249620B0170EA19FF201DE94", + "windows/amd64": "88F1ADDBAE6BDD83EC2C067470C1F56B6D0D3BA35F49AD34603F2502CB2933F3", } } diff --git a/tests/3064/aqua.yaml b/tests/3064/aqua.yaml new file mode 100644 index 000000000..ac8074e02 --- /dev/null +++ b/tests/3064/aqua.yaml @@ -0,0 +1,14 @@ +--- +# aqua - Declarative CLI Version Manager +# https://aquaproj.github.io/ +checksum: + enabled: true + require_checksum: false +# supported_envs: +# - all +registries: +- type: standard + ref: v4.218.0 # renovate: depName=aquaproj/aqua-registry +packages: +- name: suzuki-shunsuke/cmdx + version: v1.7.4