From e7a771c8a7749a71f14f60c66771c601fb9ceefb Mon Sep 17 00:00:00 2001 From: HashMapsData2Value <83883690+HashMapsData2Value@users.noreply.github.com> Date: Thu, 17 Oct 2024 19:45:15 +0200 Subject: [PATCH] ci: switch to vladopajic's package --- .github/workflows/test.yaml | 36 ++++++++++++++---------------------- 1 file changed, 14 insertions(+), 22 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 9f2bd5b..75ed981 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -3,9 +3,6 @@ name: Tests on: pull_request: types: [opened, reopened, synchronize] - push: - branches: - - "main" jobs: build: @@ -45,24 +42,19 @@ jobs: run: go build . - name: Test with the Go CLI - run: go test -cover -coverprofile=coverage.txt ./... + run: go test ./... -coverprofile=./cover.out -covermode=atomic -coverpkg=./... - - name: Archive code coverage results - uses: actions/upload-artifact@v4 + - name: check test coverage + uses: vladopajic/go-test-coverage@v2 with: - name: code-coverage - path: coverage.txt - - code_coverage: - name: "Code coverage report" - runs-on: ubuntu-latest - needs: build - permissions: - contents: read - actions: read - pull-requests: write - steps: - - uses: fgrosse/go-coverage-report@v1.1.1 - with: - coverage-artifact-name: "code-coverage" - coverage-file-name: "coverage.txt" + # Configure action using config file (option 1) + config: ./.testcoverage.yml + + # Configure action by specifying input parameters individually (option 2). + # If you are using config file (option 1) you shouldn't use these parameters, however + # specifing these action parameters will override appropriate config values. + profile: cover.out + local-prefix: github.com/algorandfoundation/hack-tui + threshold-file: 80 + threshold-package: 80 + threshold-total: 95