Open
Conversation
…cs, generate_rss, check_links)
This was referenced Apr 22, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds unit tests under tests/unit/build_scripts/ to cover several Python build/validation scripts, improving reliability across platforms and catching regressions in packaging/docs/link-check tooling.
Changes:
- Added unit tests for
validate_docsTOC parsing / missing-file validation / orphan detection. - Added unit tests for
prepare_packagefrontend build and packaging copy behavior. - Added unit tests for
generate_rssdate extraction and blog markdown parsing, pluscheck_linksURL extraction and resolution helpers.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 8 comments.
| File | Description |
|---|---|
tests/unit/build_scripts/test_prepare_package.py |
Tests frontend build failure/success paths and frontend dist copy behavior. |
tests/unit/build_scripts/test_validate_docs.py |
Tests TOC parsing, referenced-file validation, and orphaned doc detection. |
tests/unit/build_scripts/test_generate_rss.py |
Tests filename date parsing and blog markdown parsing helpers. |
tests/unit/build_scripts/test_check_links.py |
Tests URL extraction, fragment stripping, and relative URL resolution. |
… safe rss loading
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.
Closes #1570
Adds unit tests for 4 build scripts as requested by @romanlutz in #1569.
test_prepare_package.py— 9 tests covering npm lookup, install/build failures, and frontend copy logictest_validate_docs.py— 14 tests covering TOC parsing, missing file detection, and orphaned file checkstest_generate_rss.py— 10 tests covering date extraction and blog markdown parsingtest_check_links.py— 13 tests covering URL extraction, fragment stripping, and relative URL resolutionAdded 46 unit tests across 4 new test files.
All 65 tests in tests/unit/build_scripts/ pass locally:
python -m pytest tests/unit/build_scripts/ -v
65 passed
No documentation changes required.
No JupyText changes required.