From f938821960c72dc86bc3431dca65d65e7b847f25 Mon Sep 17 00:00:00 2001 From: Vaibhav Kamra Date: Wed, 16 Nov 2022 05:20:31 -0800 Subject: [PATCH] Compile all tests in cache populate step (#1534) ## Description Compile all tests in cache populate step. The previous logic would only compile the test in the local directory. ## Type of change - [ ] :sunflower: Feature - [ ] :bug: Bugfix - [ ] :world_map: Documentation - [ ] :robot: Test - [x] :computer: CI/Deployment - [ ] :hamster: Trivial/Minor ## Issue(s) * # ## Test Plan - [ ] :muscle: Manual - [ ] :zap: Unit test - [ ] :green_heart: E2E --- .github/actions/go-setup-cache/action.yml | 4 ++-- .github/workflows/ci.yml | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/actions/go-setup-cache/action.yml b/.github/actions/go-setup-cache/action.yml index 6525e80f3..316aca3c6 100644 --- a/.github/actions/go-setup-cache/action.yml +++ b/.github/actions/go-setup-cache/action.yml @@ -56,6 +56,6 @@ runs: # cover all the bases, just to be make sure we loaded everything we'll use run: | go mod download -x - go build -o compile - go test -v -c -o compile_test + go build ./... + go test -run=nope ./... shell: bash diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 87308e6a5..cd239e462 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -151,7 +151,6 @@ jobs: uses: magnetikonline/action-golang-cache@v3 with: go-version-file: src/go.mod - cache-key-suffix: -testsuite - run: mkdir testlog @@ -214,7 +213,6 @@ jobs: uses: magnetikonline/action-golang-cache@v3 with: go-version-file: src/go.mod - cache-key-suffix: -lint - name: Go Lint uses: golangci/golangci-lint-action@v3