fix: use ./... in CI and restore local dev host connection
Backend Tests / test (push) Successful in 1m3s

CI test command: switch from explicit package list to ./... so new
packages are automatically included.

local-dev-2.sh: override POSTGRES_HOST=localhost for the host-side
go run -tags dev ./main.go. The dev-tagged Connect() now reads
POSTGRES_HOST from env (needed for CI where service containers use
Docker DNS). Locally, .env sets POSTGRES_HOST=postgres, but that
name only resolves inside Docker — not from the host where the dev
server runs. Override to localhost so it connects via Docker's port
forwarding.
This commit is contained in:
2026-06-25 12:11:45 +01:00
parent 3fd66d5414
commit 1b982b118b
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -60,7 +60,7 @@ jobs:
- name: Test (all packages)
working-directory: backend
run: go test -tags "test,dev" -count=1 -v -timeout 120s ./handlers/... ./auth/... ./mw/... ./internal/... ./db/...
run: go test -tags "test,dev" -count=1 -v -timeout 180s ./...
env:
POSTGRES_HOST: postgres
TEST_DB_HOST: postgres