diff options
| author | Taras Madan <tarasmadan@google.com> | 2025-01-23 21:54:41 +0100 |
|---|---|---|
| committer | Taras Madan <tarasmadan@google.com> | 2025-01-27 10:05:21 +0000 |
| commit | 2bf68614de1620ef12f086d9e86d5c8b334bf32d (patch) | |
| tree | 24b69669a1ee44c1a34988d917cb248faed40cd3 /dashboard/app/config.go | |
| parent | 0868754a9d325ba9011e1cb74510f68d4b627c79 (diff) | |
dashboard/app: test coverage /file link
1. Init coveragedb client once and propagate it through context to enable mocking.
2. Always init coverage handlers. It simplifies testing.
3. Read webGit and coveragedb client from ctx to make it mockable.
4. Use int for file line number and int64 for merged coverage.
5. Add tests.
Diffstat (limited to 'dashboard/app/config.go')
| -rw-r--r-- | dashboard/app/config.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/dashboard/app/config.go b/dashboard/app/config.go index 6d173cb19..c71d09d8e 100644 --- a/dashboard/app/config.go +++ b/dashboard/app/config.go @@ -425,6 +425,7 @@ func installConfig(cfg *GlobalConfig) { initAPIHandlers() initKcidb() initBatchProcessors() + initCoverageDB() } var contextConfigKey = "Updated config (to be used during tests). Use only in tests!" |
