on: push: branches: - "*" name: ๐Ÿงช โœจ Unit Tests Workflow jobs: test-go: env: GO_VERSION: '1.24.3' NODE_TLS_REJECT_UNAUTHORIZED: 0 name: ๐Ÿ” ๐Ÿน Go Tests runs-on: ubuntu-latest steps: - name: ๐Ÿ›ก๏ธ ๐Ÿ”’ Add Siteworx CA Certificates run: | curl -Ls https://siteworxpro.com/hosted/Siteworx+Root+CA.pem -o /usr/local/share/ca-certificates/sw.crt update-ca-certificates - name: โš™๏ธ ๐Ÿน Set up Go Environment uses: actions/setup-go@v2 with: go-version: ${{ env.GO_VERSION }} cache: true - name: ๐Ÿ“– ๐Ÿ” Checkout Repository Code uses: actions/checkout@v2 with: fetch-depth: 1 - name: ๐Ÿ“ฆ ๐Ÿ“ฅ Install Dependencies run: | go mod download - name: โœ… ๐Ÿ” Run Go Tests run: | go test -v ./... -coverprofile=coverage.out - name: ๐Ÿ“Š ๐Ÿ“ˆ Upload Coverage Report uses: christopherhx/gitea-upload-artifact@v4 with: name: coverage-report path: coverage.out retention-days: 7