diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml new file mode 100644 index 0000000000..1872969dd4 --- /dev/null +++ b/.github/workflows/coverage.yml @@ -0,0 +1,37 @@ +name: Coverage + +on: + pull_request: + branches: + - main + - '[0-9]+.[0-9]+' + types: [ assigned, opened, synchronize, reopened ] + push: + branches: + - main + +env: + K8S_MANIFEST_DIR: deploy + GO_VERSION: 1.18.2 + +jobs: + coverage: + name: Unit Tests + runs-on: ubuntu-latest + timeout-minutes: 15 + steps: + - name: Check out the repo + uses: actions/checkout@v2 + + - name: Set up Go + uses: actions/setup-go@v2 + with: + go-version: ${{ env.GO_VERSION }} + + - name: Update coverage + run: go install github.com/mattn/goveralls@latest + + - name: Send coverage + env: + COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: goveralls -service=github \ No newline at end of file diff --git a/.github/workflows/unit-test.yml b/.github/workflows/unit-test.yml index 0062b2f01c..c2e84799fe 100644 --- a/.github/workflows/unit-test.yml +++ b/.github/workflows/unit-test.yml @@ -42,13 +42,6 @@ jobs: run: | GOOS=linux go test ./... - - name: Update coverage - run: go install github.com/mattn/goveralls@latest - - name: Send coverage - env: - COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: goveralls -service=github - manifest_tests: name: Manifest Tests runs-on: ubuntu-latest