Skip to content

Refactor - #BKP-NoId - Bump actions/checkout from 6 to 7 #13

Refactor - #BKP-NoId - Bump actions/checkout from 6 to 7

Refactor - #BKP-NoId - Bump actions/checkout from 6 to 7 #13

Workflow file for this run

name: Go CI
on:
push:
branches: [main]
pull_request:
jobs:
lint-and-unit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v6
with:
go-version: "1.26"
- name: gofmt
run: test -z "$(gofmt -l .)" || { gofmt -l .; exit 1; }
- name: go vet
run: go vet ./...
- name: golangci-lint
uses: golangci/golangci-lint-action@v9
with:
version: latest
- name: Unit tests
run: go test ./...
integration:
runs-on: ubuntu-latest
needs: lint-and-unit
if: github.event_name == 'pull_request'
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v6
with:
go-version: "1.26"
- name: Install dump tools (Debian paths)
run: |
sudo install -d /usr/share/postgresql-common/pgdg
sudo curl -fsSL https://www.postgresql.org/media/keys/ACCC4CF8.asc \
-o /usr/share/postgresql-common/pgdg/apt.postgresql.org.asc
echo "deb [signed-by=/usr/share/postgresql-common/pgdg/apt.postgresql.org.asc] http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" \
| sudo tee /etc/apt/sources.list.d/pgdg.list
sudo apt-get update
sudo apt-get install -y postgresql-client-18 mariadb-client
wget -q "https://fastdl.mongodb.org/tools/db/mongodb-database-tools-ubuntu2204-x86_64-100.14.0.tgz" -O /tmp/mt.tgz
sudo tar -xzf /tmp/mt.tgz -C /usr/local/bin --strip-components=2 --wildcards '*/bin/*'
- name: Integration tests
run: go test -tags integration -v ./internal/integration/