Skip to content

Wait for valid start time to submit (#919) #2767

Wait for valid start time to submit (#919)

Wait for valid start time to submit (#919) #2767

Workflow file for this run

name: Go Test
on: push
jobs:
unit-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
name: Setup GO Env
with:
go-version: '1.20'
- name: Cache Go Test modules
uses: actions/cache@v2
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-test-${{ secrets.CACHE_VERSION }}-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-test-
- name: Run Unit Tests with Coverage
run: >-
for d in $(go list ./... | grep -v e2e); do
go test -race -coverprofile=profile.out -covermode=atomic $d
if [ -f profile.out ]; then
cat profile.out >> coverage.txt
rm profile.out
fi
done
shell: bash
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
files: ./coverage.txt
flags: unittests
name: codecov-umbrella
verbose: true