Skip to content

CLOUDP-250827: renaming data files (#41) #144

CLOUDP-250827: renaming data files (#41)

CLOUDP-250827: renaming data files (#41) #144

name: 'Code Health Tools'
on:
push:
branches:
- main
paths:
- 'tools/**'
pull_request: {}
workflow_dispatch: {}
workflow_call: {}
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout CLI
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29
- name: Install Go
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7
with:
go-version-file: 'tools/cli/go.mod'
- name: Build CLI
working-directory: tools/cli
run: make build
unit-tests:
needs: build
env:
COVERAGE: coverage.out
UNIT_TAGS: unit
INTEGRATION_TAGS: integration
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29
- name: Install Go
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7
with:
go-version-file: 'tools/cli/go.mod'
- name: Run unit tests
working-directory: tools/cli
run: make unit-test
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29
with:
sparse-checkout: |
.github
tools
- name: Install Go
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7
with:
go-version-file: 'tools/cli/go.mod'
cache: false # see https://github.com/golangci/golangci-lint-action/issues/807
- name: golangci-lint
uses: golangci/golangci-lint-action@a4f60bb28d35aeee14e6880718e0c85ff1882e64
with:
version: v1.58.1
working-directory: tools/cli
- name: Checkout GitHub actions
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29
with:
sparse-checkout: |
.github
- name: Download actionlint
id: get_actionlint
run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
shell: bash
- name: Check workflow files
run: |
echo "::add-matcher::.github/actionlint-matcher.json"
${{ steps.get_actionlint.outputs.executable }} -color
shell: bash
e2e-tests:
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b
- name: Install Go
uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7
with:
go-version-file: 'tools/cli/go.mod'
- name: Run e2e tests
working-directory: tools/cli
run: make e2e-test