feature/xml2 port - #26
Open
LiNk-NY wants to merge 6 commits into
Open
Conversation
LiNk-NY
commented
Jul 6, 2026
Contributor
- migrate XML to xml2
- add unit tests for getHtmlTitle, getDocumentTitles, and getVignetteIndexEntry
There was a problem hiding this comment.
Pull request overview
Ports HTML/XML handling from XML to xml2 by introducing compatibility wrappers and updating title extraction, along with adding RUnit tests and small fixture files to validate behavior.
Changes:
- Added
R/xml2_helpers.RimplementingxmlNode(),xmlOutputDOM()/xmlTree(), andsaveXML()equivalents on top ofxml2. - Updated
getHtmlTitle()to parse HTML titles withxml2instead ofXML/XPath helpers. - Added RUnit tests plus minimal
inst/extdatafixtures for vignette title extraction paths.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| R/xml2_helpers.R | Adds xml2-based compatibility wrappers for legacy XML DOM-building and serialization APIs. |
| R/repository.R | Switches HTML title parsing from XML to xml2. |
| NAMESPACE | Removes XML imports and adds xml2 imports. |
| inst/unitTests/test_repository.R | Adds unit tests covering getHtmlTitle, getDocumentTitles, and getVignetteIndexEntry. |
| inst/extdata/vignette.Rmd | Adds a source vignette fixture containing \\VignetteIndexEntry. |
| inst/extdata/vignette.html | Adds an HTML fixture with a <title> element. |
| DESCRIPTION | Replaces XML with xml2 in Imports and updates Collate to include the new helper file. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
LiNk-NY
marked this pull request as ready for review
July 7, 2026 21:47
authored-by: gemini 3.5 flash
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
LiNk-NY
force-pushed
the
feature/xml2_port
branch
from
July 7, 2026 21:49
df1c778 to
7dad419
Compare
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.