diff --git a/.github/workflows/main_template.yml b/.github/workflows/main_template.yml index 8efb0277816..e681c91e6d7 100644 --- a/.github/workflows/main_template.yml +++ b/.github/workflows/main_template.yml @@ -30,8 +30,7 @@ jobs: uses: ./.github/workflows/test_template.yml with: modulepath: ${{ inputs.modulepath }} - tests-timeout: "30m" + tests-timeout: "40m" go-version: "1.22.x" secrets: codecov-token: ${{ secrets.codecov-token }} - \ No newline at end of file diff --git a/.github/workflows/test_template.yml b/.github/workflows/test_template.yml index 38fa10e096b..bb94b17da76 100644 --- a/.github/workflows/test_template.yml +++ b/.github/workflows/test_template.yml @@ -36,13 +36,17 @@ jobs: mkdir -p "$GOCOVERDIR" "$TXTARCOVERDIR" "$COVERDIR" # Craft a filter flag based on the module path to avoid expanding coverage on unrelated tags. - export filter="-pkg=github.com/gnolang/gno/${{ inputs.modulepath }}/..." + export coverpkg="github.com/gnolang/gno/${{ inputs.modulepath }}/..." + export filter="-pkg=$coverpkg" # XXX: Simplify coverage of txtar - the current setup is a bit # confusing and meticulous. There will be some improvements in Go # 1.23 regarding coverage, so we can use this as a workaround until # then. - go test -covermode=atomic -timeout ${{ inputs.tests-timeout }} ./... -test.gocoverdir=$GOCOVERDIR + go test ./... -coverpkg=$coverpkg \ + -covermode=atomic \ + -timeout ${{ inputs.tests-timeout }} \ + -test.gocoverdir=$GOCOVERDIR # Print results (set +x; echo 'go coverage results:')