From 7ab73a83175a141e0d2b23de160462a943a8d992 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Mur=C3=A9?= Date: Fri, 30 Aug 2024 22:57:09 +0200 Subject: [PATCH] add GHA workflow to run go tests --- .github/workflows/gotest.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/gotest.yml diff --git a/.github/workflows/gotest.yml b/.github/workflows/gotest.yml new file mode 100644 index 0000000..7632e29 --- /dev/null +++ b/.github/workflows/gotest.yml @@ -0,0 +1,27 @@ +on: [push, pull_request] +name: Go Test + +jobs: + unit: + strategy: + fail-fast: false + matrix: + os: [ "ubuntu" ] + go: [ "1.21.x", "1.22.x", "1.23.x", ] + env: + COVERAGES: "" + runs-on: ${{ matrix.os }}-latest + name: ${{ matrix.os}} (go ${{ matrix.go }}) + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-go@v2 + with: + go-version: ${{ matrix.go }} + - name: Go information + run: | + go version + go env + - name: Run tests + run: go test -v ./... + - name: Check formatted + run: gofmt -l . \ No newline at end of file