refactor(release): Extract gh-pages file manipulation code into a tested class#470
refactor(release): Extract gh-pages file manipulation code into a tested class#470
Conversation
There was a problem hiding this comment.
Pull request overview
This PR refactors gh-pages generation and update behavior by extracting the file manipulation logic into a dedicated Toys::Release::GhPagesLogic class and adding a comprehensive test suite around it, reducing duplication across the release tooling.
Changes:
- Introduces
Toys::Release::GhPagesLogicto encapsulate gh-pages scaffolding generation, v0 directory cleanup, and version-page updates. - Updates
gen-gh-pagestool and the releasePUSH_GH_PAGESstep to use the new logic class instead of inline file operations. - Adds a new Minitest suite validating generated content, callbacks/results behavior, and update behavior.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| toys-release/toys/gen-gh-pages.rb | Switches gh-pages generation to use GhPagesLogic for cleanup and scaffold creation. |
| toys-release/toys/.lib/toys/release/gh_pages_logic.rb | New class containing gh-pages generation and update logic. |
| toys-release/toys/.lib/toys/release/steps.rb | Uses GhPagesLogic#update_version_pages during gh-pages publication. |
| toys-release/toys/.test/test_gh_pages_logic.rb | New tests covering generation, cleanup, and version update behaviors. |
| toys-release/toys/.test/helper.rb | Loads gh_pages_logic for the test suite. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
f9b1212 to
8ad81ec
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
8ad81ec to
28532b1
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
28532b1 to
5f68c83
Compare
5f68c83 to
c419a6c
Compare
No description provided.