Improve test coverage to 95.3% - #9
Merged
Merged
Conversation
- Engine package: 91.1% → 92.9% - Added error path tests for scheduler, fetcher, fragment, rss, scraper - Added DB error tests via collection deletion - Added lifecycle test for scheduler Start/Stop - Added coverage for browser fallback error paths - Added tests for fragment dedup, similarity matching, and hash persistence - AI package: 96.4% → 98.0% - Added error path tests for preference regeneration - Added tests for savePreferenceProfile collection missing - Added tests for countCorrectionsSinceLastProfile DB errors - Routes package: 100% (maintained) - UI tests: 32 tests passing (auth-store, markdown, theme, StarRating) - Decision log: browser.go functions requiring Chrome are accepted as integration-test-only code, mocked via BrowserExtractFunc/BrowserFetchBodyFunc Total coverage: 95.3% (target: ≥95%)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Comprehensive test coverage improvements across all packages:
Coverage Results
What Changed
Key Decision
Browser.go functions (defaultBrowserExtract, launchBrowser, openStealthPage, waitForContent) require a real Chrome browser and are accepted as integration-test-only code. They are mocked in all other tests via BrowserExtractFunc/BrowserFetchBodyFunc override variables. See decisions-2026-03-01-test-coverage.log.