mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-10 09:56:55 +00:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 3.4.0 to 3.5.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](24cb908017...8f4b7f8486
)
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Co-authored-by: kyverno-bot <104836976+kyverno-bot@users.noreply.github.com>
46 lines
1.3 KiB
YAML
46 lines
1.3 KiB
YAML
name: cli
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- '*'
|
|
pull_request:
|
|
branches:
|
|
- 'main'
|
|
- 'release*'
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
cli-test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 # v3.5.0
|
|
- name: Setup build env
|
|
uses: ./.github/actions/setup-build-env
|
|
with:
|
|
build-cache-key: cli-test
|
|
- name: Setup TEST_GIT_BRANCH
|
|
run: |
|
|
if [[ ${{ github.event_name }} == "push" ]]
|
|
then
|
|
export TEST_GIT_BRANCH=${GITHUB_REF##*/}
|
|
elif [[ ${{ github.event_name }} == "pull_request" ]]
|
|
then
|
|
export TEST_GIT_BRANCH=${{ github.event.pull_request.base.ref }}
|
|
fi
|
|
- name: Test CLI
|
|
run: |
|
|
make test-cli
|
|
- name: Test CLI (failures)
|
|
run: |
|
|
CLI_PATH=$PWD/cmd/cli/kubectl-kyverno/kubectl-kyverno
|
|
$CLI_PATH test ./test/cli/test-fail/missing-policy && exit 1 || exit 0
|
|
$CLI_PATH test ./test/cli/test-fail/missing-rule && exit 1 || exit 0
|
|
$CLI_PATH test ./test/cli/test-fail/missing-resource && exit 1 || exit 0
|