Skip to content

Add coverage test for project config documentation - #1844

Merged
max-sixty merged 1 commit into
mainfrom
project-config-section-test
Apr 1, 2026
Merged

max-sixty merged 1 commit into
mainfrom
project-config-section-test

Conversation

@max-sixty

Copy link
Copy Markdown
Owner

Mirrors test_config_docs_include_all_sections (user config) for the project config side. Verifies that the PROJECT_CONFIG_START/PROJECT_CONFIG_END section in src/cli/mod.rs includes all ProjectConfig sections ([list], [forge], [step.copy-ignored], [aliases]), excludes deprecated [ci], and documents at least one hook key.

Without this, a new field could be added to ProjectConfig without appearing in the generated wt.example.toml.

This was written by Claude Code on behalf of @max-sixty

Verifies all ProjectConfig sections ([list], [forge], [step.copy-ignored],
[aliases]) appear in the project config example, deprecated [ci] does not,
and at least one hook key is documented. Mirrors the existing
test_config_docs_include_all_sections for user config.

Co-Authored-By: Claude <[email protected]>
@max-sixty
max-sixty merged commit 3280add into main Apr 1, 2026
23 checks passed
@max-sixty
max-sixty deleted the project-config-section-test branch April 1, 2026 01:25
max-sixty added a commit that referenced this pull request Apr 1, 2026
Replace hand-curated `required_sections` arrays in
`test_config_docs_include_all_sections` and
`test_project_config_docs_include_all_sections` with section lists
derived from `valid_user_config_keys()` / `valid_project_config_keys()`
(powered by the existing JsonSchema derive). Adding a new field to
`ProjectConfig` or `UserConfig` now automatically fails the test if docs
aren't updated — no need to also update the test.

Follows up on #1844 which added the project config test with a
hand-curated list.

> _This was written by Claude Code on behalf of @max-sixty_

Co-authored-by: Claude <[email protected]>
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.

2 participants