Skip to content

Add config and githubapp test coverage#4

Merged
hermanngeorge15 merged 1 commit into
mainfrom
feat/remaining-coverage
Mar 12, 2026
Merged

Add config and githubapp test coverage#4
hermanngeorge15 merged 1 commit into
mainfrom
feat/remaining-coverage

Conversation

@hermanngeorge15
Copy link
Copy Markdown
Contributor

Summary

  • Config package: 49% → 93.3% coverage — tests for Load (valid file, missing file, invalid YAML, validation errors, env var overrides), applyDefaults, DefaultConfig, ParseRepo edge cases (unknown host, two-part path), DefaultConfigPath, port bounds validation
  • GitHubApp package: 44% → 82.3% coverage — tests for ListInstallations, GetInstallationToken, ListRepos using httptest.NewServer mock HTTP servers, including success, error, and empty response paths
  • Made githubapp.App.baseURL configurable (unexported field) for testability
  • Created UnityInFlow/homebrew-tap GitHub repository for future Homebrew formula distribution

Test plan

  • go test ./internal/config/ -cover → 93.3%
  • go test ./internal/githubapp/ -cover → 82.3%
  • go test ./... -count=1 — all packages pass
  • go vet ./... — clean

🤖 Generated with Claude Code

Config coverage: 49% → 93.3% (Load, applyDefaults, DefaultConfig,
ParseRepo edge cases, env var overrides, validation boundaries).
GitHubApp coverage: 44% → 82.3% (ListInstallations, GetInstallationToken,
ListRepos with httptest mock servers, error paths).

Make githubapp.App.baseURL configurable for testability.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@hermanngeorge15 hermanngeorge15 merged commit 929623e into main Mar 12, 2026
3 checks passed
@hermanngeorge15 hermanngeorge15 deleted the feat/remaining-coverage branch March 12, 2026 11:52
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