Skip to content

Go CI: unit tests, race-enabled checks, and cmd/internal structure - #18

Merged
Semih702 merged 1 commit into
mainfrom
ci/go-quality-and-tests
Feb 9, 2026
Merged

Go CI: unit tests, race-enabled checks, and cmd/internal structure#18
Semih702 merged 1 commit into
mainfrom
ci/go-quality-and-tests

Conversation

@Semih702

@Semih702 Semih702 commented Feb 9, 2026

Copy link
Copy Markdown
Owner

What’s included

This PR introduces a proper Go quality gate for the project and aligns both
proxy and collector with industry-standard Go project structure.

✅ Code & Structure

  • Split binaries into cmd/* and core logic into internal/*
  • No behavior or feature changes in runtime logic
  • Improved testability and maintainability

✅ Unit Tests

  • Added unit tests for core logic (request handling, validation, helpers)
  • Tests live under internal/* packages

✅ CI Quality Gate (PR blocking)

  • gofmt formatting check
  • go mod tidy + go mod verify
  • go vet ./...
  • go test -race ./... (race detector enabled)

CI runs per-module (proxy, collector) and remains fast enough for every PR.

Why

  • Catch data races early in concurrency-heavy code paths
  • Ensure consistent formatting and dependency hygiene
  • Make future changes safer and easier to review

Notes

  • All tests are executed with the Go race detector enabled
  • No production behavior or API changes introduced

@Semih702
Semih702 merged commit 5c4564f into main Feb 9, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant