Repository navigation
test(display): split template repo handler tests to match source files - #2171
Merged
TerryHowe merged 1 commit intoSep 18, 2026
Merged
Conversation
template/repo_test.go held the tests for both repo_list.go and repo_tags.go, while every other test file under display/metadata pairs 1:1 with its source. Split it into repo_list_test.go and repo_tags_test.go. repo_test.go is moved to repo_list_test.go so history for the list tests is kept. No test body or assertion changes: `go test -list .` reports the same 26 tests before and after, and package coverage stays at 85.3%. Signed-off-by: Akshita <[email protected]>
akshita317
requested review from
TerryHowe,
Wwwsylvia,
sabre1041,
sajayantony and
shizhMSFT
as code owners
September 14, 2026 16:07
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2171 +/- ##
==========================================
+ Coverage 87.71% 87.74% +0.03%
==========================================
Files 139 139
Lines 5689 5689
==========================================
+ Hits 4990 4992 +2
+ Misses 419 417 -2
Partials 280 280 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Member
|
Thanks! |
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.
Follow-up from review of #2164.
Change
template/repo_test.goheld the tests for two source files,repo_list.goandrepo_tags.go. Every other test file underdisplay/metadata/pairs 1:1 with its source, so this splits it:repo_list_test.goTestNewRepoListHandler,TestRepoListHandler_Render,TestRepoListHandler_Render_empty,TestRepoListHandler_Render_invalidTemplaterepo_tags_test.goTestNewRepoTagsHandler,TestRepoTagsHandler_Render,TestRepoTagsHandler_Render_empty,TestRepoTagsHandler_Render_invalidTemplaterepo_test.gois moved torepo_list_test.go(git detects the rename), so history for the list tests is preserved.Verification
This only moves code; no test body or assertion is changed.
go test -list .on the package gives the same 26 test names before and after (diffed)gofmtandgo vetare cleanNo production code is changed.