Skip to content

fix: made tests os dependent#456

Merged
hanneshapke merged 1 commit into
mainfrom
fix/gate-tests-by-os
May 20, 2026
Merged

fix: made tests os dependent#456
hanneshapke merged 1 commit into
mainfrom
fix/gate-tests-by-os

Conversation

@hanneshapke
Copy link
Copy Markdown
Collaborator

@hanneshapke hanneshapke commented May 20, 2026

Summary

  • TestAppDataDir_Linux was running on all platforms and failing on darwin because it asserts Linux-specific paths (/xdg/home/..., /home/user/.kiji-proxy, /var/lib/kiji-proxy) against AppDataDir(), which short-circuits to ~/Library/Application Support/Kiji Privacy Proxy on darwin.
  • Renamed paths_test.gopaths_linux_test.go so Go's filename-based build constraint scopes the test to Linux only — no //go:build tag needed.
  • Added paths_darwin_test.go so the darwin branch of AppDataDir() (previously uncovered) is exercised on macOS hosts.

No behavior change in paths.go; this is test hygiene only.

Test plan

  • go test ./src/backend/paths/... passes on darwin (runs TestAppDataDir_Darwin, skips Linux test via filename).
  • GOOS=linux go vet ./src/backend/paths/... clean — Linux build still includes the original test.
  • make test-go passes end-to-end on darwin.
  • CI to confirm TestAppDataDir_Linux still runs and passes on the Linux runner.

@hanneshapke hanneshapke merged commit b3a7c87 into main May 20, 2026
10 checks passed
@hanneshapke hanneshapke deleted the fix/gate-tests-by-os branch May 20, 2026 05:13
@github-actions github-actions Bot locked and limited conversation to collaborators May 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant