Add CI and integration workflows

This commit is contained in:
Rustem Kamalov
2026-04-14 01:04:32 +03:00
parent 9e22f68c6f
commit bc59de46fb
3 changed files with 64 additions and 1 deletions

36
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,36 @@
name: CI
on:
push:
branches: [main, tests]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
test-build-lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: "1.24"
cache: true
- name: Run unit tests
run: go test -race -count=1 ./...
- name: Run go vet
run: go vet ./...
- name: Build
run: go build .
- name: Run golangci-lint
uses: golangci/golangci-lint-action@v6

27
.github/workflows/integration.yml vendored Normal file
View File

@@ -0,0 +1,27 @@
name: Integration Tests
on:
workflow_dispatch:
permissions:
contents: read
jobs:
integration:
runs-on: ubuntu-latest
env:
OPENSERP_INTEGRATION_TESTS: "1"
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: "1.24"
cache: true
- name: Run integration tests
run: go test -race -count=1 -timeout=120s -tags=integration ./...

View File

@@ -14,7 +14,7 @@ import (
)
const (
version = "0.6.0"
version = "0.6.2"
defaultConfigFilename = "config"
envPrefix = "OPENSERP"
)