Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[IND-4226] [COMPLIANCE] Update Copyright Headers #172

[IND-4226] [COMPLIANCE] Update Copyright Headers

[IND-4226] [COMPLIANCE] Update Copyright Headers #172

Workflow file for this run

name: hil
on:
- push
- pull_request
permissions:
contents: read
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Setup Go
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
with:
go-version: '1.23'
- name: Run golangci-lint
uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # v8.0.0
linux-tests:
runs-on: ubuntu-latest
env:
TEST_RESULTS_PATH: "/tmp/test-results"
strategy:
matrix:
go-version:
- 'oldstable'
- 'stable'
steps:
- name: Checkout code
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Make Test Directory
run: mkdir -p "$TEST_RESULTS_PATH"/hil
- name: Setup Go
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
with:
go-version: ${{ matrix.go-version }}
- name: Install gotestsum
uses: autero1/action-gotestsum@7263b9d73912eec65f46337689e59fac865c425f # v2.0.0
with:
gotestsum_version: 1.9.0
- name: Run gotestsum
env:
PLATFORM: linux
REPORT_FILE: ${{ env.TEST_RESULTS_PATH }}/hil/gotestsum-report.xml
run: |-
gotestsum --format=short-verbose --junitfile ${{ env.REPORT_FILE }} -- -p 2 -cover -coverprofile=coverage-linux.out ./...
- name: Upload Test Results
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
path: ${{ env.TEST_RESULTS_PATH }}
name: tests-linux-${{matrix.go-version}}
- name: Upload coverage report
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
path: coverage-linux.out
name: Coverage-report-linux-${{matrix.go-version}}
- name: Display coverage report
run: go tool cover -func=coverage-linux.out
windows-tests:
runs-on: windows-latest
env:
TEST_RESULTS_PATH: 'c:\Users\runneradmin\AppData\Local\Temp\test-results'
strategy:
matrix:
go-version:
- 'oldstable'
- 'stable'
steps:
- run: git config --global core.autocrlf false
- name: Checkout code
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Setup Go
uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 # v6.0.0
with:
go-version: ${{ matrix.go-version }}
- name: Install gotestsum
uses: autero1/action-gotestsum@7263b9d73912eec65f46337689e59fac865c425f # v2.0.0
with:
gotestsum_version: 1.9.0
- name: Run gotestsum
env:
PLATFORM: windows
REPORT_FILE: ${{ env.TEST_RESULTS_PATH }}/hil/gotestsum-report.xml
run: |-
gotestsum.exe --format=short-verbose --junitfile ${{ env.REPORT_FILE }} -- -p 2 -cover -coverprofile="coverage-win.out" ./...
- name: Upload Test Results
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
path: ${{ env.TEST_RESULTS_PATH }}
name: tests-windows-${{matrix.go-version}}
- name: Upload coverage report
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
with:
path: coverage-win.out
name: Coverage-report-windows-${{matrix.go-version}}
- name: Display coverage report
run: go tool cover -func=coverage-win.out
shell: cmd