UI Responsivity and Technical Improvements #481
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: golangci-test | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
golangci: | |
uses: ./.github/workflows/golangci-lint.yml | |
unit-tests: | |
needs: golangci | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: 'go.mod' | |
- run: go version | |
- name: Install dependencies | |
run: make check-tensorflow | |
- name: Set environment variables for CGO | |
run: | | |
echo "CGO_ENABLED=1" >> $GITHUB_ENV | |
echo "CGO_CFLAGS=-I $HOME/src/tensorflow" >> $GITHUB_ENV | |
- name: Set up gotestfmt | |
run: go install github.com/gotesttools/gotestfmt/v2/cmd/gotestfmt@latest | |
- name: Run unit tests | |
run: | | |
set -euo pipefail | |
go test -json -v ./... 2>&1 | tee /tmp/gotest.log | gotestfmt -ci github | |
- name: Upload test log | |
uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: test-log | |
path: /tmp/gotest.log | |
if-no-files-found: error |