Skip to content

test: regroup added tests into a few thematic files by function#71

Merged
vt128 merged 1 commit into
masterfrom
regroup-tests
Jun 12, 2026
Merged

test: regroup added tests into a few thematic files by function#71
vt128 merged 1 commit into
masterfrom
regroup-tests

Conversation

@vt128

@vt128 vt128 commented Jun 12, 2026

Copy link
Copy Markdown
Member

Why

The hardening work scattered tests across many small single-purpose files (one per fix/feature). Regroup everything I added into a few thematic files, leaving the source-shaped test files untouched (conv/map/slice/struct/interface/value/call/func/extern/util). No test logic changes — 210 → 210 test funcs, suite green. convert test files 21 → 15, root 3 → 2.

New structure

Black-box (convert_test):

file theme absorbed
keys_test.go map keys + deterministic ordering hashable + order + identity + decorate
conversion_test.go value conversion correctness/safety checked + unwrap + review_misc (Duration/typed-nil/…)
robustness_test.go no-panic + bridge contracts + freeze/concurrency panics + safestring + bridge_contract + freeze_race

White-box (convert): internal_test.go (caches, comparableByValue, stableKeyString, panic sentinel)
Root: starlight_features_test.go (dialect + WithGlobals); starlight_test.go untouched

Each file opens with a commented section list. Also adds a test-organization rule to CLAUDE.md so future tests are added as sections, not new files. Full suite -race -count=2; Go 1.19 via Docker.

🤖 Generated with Claude Code

The hardening work scattered tests across many small single-purpose
files. Regroup everything I added into a few thematic files, leaving the
source-shaped test files (conv/map/slice/struct/interface/value/call/
func/extern/util) untouched. No test logic changes (210 -> 210 funcs,
suite green). convert test files 21 -> 15.

Black-box (convert_test):
- keys_test:       map keys + deterministic ordering
                   (hashable + order + identity + decorate)
- conversion_test: value conversion correctness/safety
                   (checked + unwrap + review_misc: Duration/typed-nil/...)
- robustness_test: no-panic + bridge contracts + freeze/concurrency
                   (panics + safestring + bridge_contract + freeze_race)
White-box (convert): internal_test (already consolidated)
Root: starlight_features_test (dialect + WithGlobals); starlight_test untouched

Each file opens with a commented section list. Also documents the test
organization rule in CLAUDE.md so future tests follow it.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@codacy-production

codacy-production Bot commented Jun 12, 2026

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

🟢 Metrics 530 complexity · 20 duplication

Metric Results
Complexity 530
Duplication 20

View in Codacy

🟢 Coverage ∅ diff coverage · +0.00% coverage variation

Metric Results
Coverage variation +0.00% coverage variation (-1.00%)
Diff coverage diff coverage

View coverage diff in Codacy

Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (2612ecc) 2124 1915 90.16%
Head commit (767589f) 2124 (+0) 1915 (+0) 90.16% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#71) 0 0 ∅ (not applicable)

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@vt128 vt128 merged commit 2e1dc40 into master Jun 12, 2026
12 checks passed
@vt128 vt128 deleted the regroup-tests branch June 12, 2026 06:36
@codecov

codecov Bot commented Jun 12, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 87.12%. Comparing base (2612ecc) to head (767589f).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master      #71   +/-   ##
=======================================
  Coverage   87.12%   87.12%           
=======================================
  Files           8        8           
  Lines        1662     1662           
=======================================
  Hits         1448     1448           
  Misses        131      131           
  Partials       83       83           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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