Skip to content

Feat/unittest (#20) #85

Feat/unittest (#20)

Feat/unittest (#20) #85

Workflow file for this run

# This workflow will build a golang project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go
name: Go Build and Test
on:
push:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.23"
- name: Build
run: go build -v ./...
test:
runs-on: ubuntu-latest
# services:
# # Label used to access the service container
# postgres:
# # Docker Hub image
# image: postgres:17
# # Provide the password for postgres
# env:
# POSTGRES_DB: test-maxit
# POSTGRES_PASSWORD: postgres
# # Set health checks to wait until postgres has started
# options: >-
# --health-cmd pg_isready
# --health-interval 10s
# --health-timeout 5s
# --health-retries 5
# ports:
# - 5432:5432
# rabbitmq:
# image: rabbitmq:3.13-management
# ports:
# - 5672:5672
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.23"
- name: Test
run: go test -v ./...