-
-
Notifications
You must be signed in to change notification settings - Fork 0
refactor: release_changelog and release_create actions to use modular scripts #47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #47 +/- ##
==========================================
Coverage 100.00% 100.00%
==========================================
Files 4 6 +2
Lines 620 798 +178
Branches 57 79 +22
==========================================
+ Hits 620 798 +178
Flags with carried forward coverage won't be shown. Click here to find out more.
|
… scripts Moved inline scripts in release_changelog and release_create actions to separate JavaScript modules (changelog.js and cleanup.js) for better maintainability and testability. Added comprehensive unit tests for both modules. This refactor improves code organization and enables easier testing and future enhancements.
104abd5 to
18aac2a
Compare
Extracted common mock and console setup logic into a new tests/testUtils.js utility module. Updated test_changelog.test.js and test_cleanup.test.js to use these shared utilities, reducing duplication and improving maintainability.
8063710 to
4d66ec8
Compare
Replaces manual release object construction in tests with new createMockRelease and createMockReleases helpers for consistency and reduced duplication. Adds these helper functions to testUtils.js and updates all relevant test files to use them.
Introduces helper functions in testUtils.js for setting up and verifying branch creation and delete operations in tests. Updates release_changelog and release_create test suites to use these helpers, reducing duplication and improving readability.
Added setupCleanupEnv and setupChangelogWorkflow utility functions to centralize environment variable and mock setup in tests. Updated release changelog and cleanup tests to use these new utilities, improving readability and maintainability. Broadened ESLint Jest config to include all test JS files.
bd7c251 to
7c3ce6b
Compare
Consolidated multiple individual tests for compareVersionTags into a single parameterized test using test.each, improving test maintainability and reducing code duplication.
|



Description
Moved inline scripts in release_changelog and release_create actions to separate JavaScript modules (changelog.js and cleanup.js) for better maintainability and testability. Added comprehensive unit tests for both modules. This refactor improves code organization and enables easier testing and future enhancements.
Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage