(Draft, not for review) Runtime manager updates #1179
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CodeCoverage Build | |
on: | |
pull_request: | |
jobs: | |
coverage: | |
name: CodeCoverage | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | |
- name: Set up Go | |
uses: actions/setup-go@v3 | |
with: | |
go-version-file: 'go.mod' | |
cache: true | |
- name: Go cache | |
uses: actions/cache@v3 | |
with: | |
# In order: | |
# * Module download cache | |
# * Build cache (Linux) | |
path: | | |
~/go/pkg/mod | |
key: ${{ runner.os }}-go-cache-${{ hashFiles('**/go.sum') }} | |
restore-keys: | | |
${{ runner.os }}-go-cache | |
- name: Run Mage | |
uses: magefile/mage-action@v2 | |
env: | |
TEST_COVERAGE: 'true' | |
with: | |
version: latest | |
args: unitTest | |
- name: Save PR information | |
run: | | |
mkdir -p ./pr | |
echo ${{ github.event.number }} > ./build/pull_request_number | |
echo ${{ github.event.pull_request.base.ref }} > ./build/pull_request_base | |
echo ${{ github.event.pull_request.head.ref }} > ./build/pull_request_branch | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: test-coverage | |
path: | | |
build/TEST-* | |
build/pull_request* | |
if-no-files-found: error |