-
-
Notifications
You must be signed in to change notification settings - Fork 638
convert testUtils to ts #2074
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
convert testUtils to ts #2074
Conversation
|
Caution Review failedThe pull request is closed. WalkthroughRefactors type safety in Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes
Poem
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Root Cause: The ci-changes-detector script was missing patterns for test files in the Pro package. When PR #2074 changed only `packages/react-on-rails-pro/tests/testUtils.ts`, the detector incorrectly classified it as a docs-only change because the pattern only matched `packages/react-on-rails-pro/src/**/*`. This triggered the ensure-master-docs-safety action, which correctly failed the workflow since the previous commit had test failures. The safety mechanism worked as intended, but the root cause was the missing pattern. Changes: - Add patterns for `packages/react-on-rails/tests/**/*` to trigger JS tests - Add patterns for `packages/react-on-rails-pro/tests/**/*` to trigger Pro tests - Add patterns for `scripts/`, `package.json`, and `tsconfig.json` in both packages - Update comments to clarify what's included in each pattern Impact: - Pro and open-source package test file changes will now correctly trigger CI - Package configuration changes will trigger appropriate test suites - Prevents false-positive "docs-only" detection that blocks deployments 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
## Summary Fixes the ci-changes-detector script to correctly identify test file changes in both the open-source and Pro packages, preventing false-positive "docs-only" detection. ## Root Cause The ci-changes-detector script was missing patterns for test files in the Pro package. When PR #2074 changed only `packages/react-on-rails-pro/tests/testUtils.ts`, the detector incorrectly classified it as a docs-only change because the pattern only matched `packages/react-on-rails-pro/src/**/*`. This triggered the ensure-master-docs-safety action, which correctly failed the workflow since the previous commit had test failures. The safety mechanism worked as intended, but the root cause was the missing pattern. ## Changes - ✅ Add patterns for `packages/react-on-rails/tests/**/*` to trigger JS tests - ✅ Add patterns for `packages/react-on-rails-pro/tests/**/*` to trigger Pro tests - ✅ Add patterns for `scripts/`, `package.json`, and `tsconfig.json` in both packages - ✅ Update comments to clarify what's included in each pattern ## Testing Tested with multiple file patterns: - ✅ `packages/react-on-rails-pro/tests/testUtils.ts` → correctly detected as PRO_JS_CHANGED - ✅ `packages/react-on-rails/tests/test.ts` → correctly detected as JS_CHANGED - ✅ `packages/react-on-rails-pro/package.json` → correctly detected as PRO_JS_CHANGED - ✅ `README.md` → correctly detected as docs_only ## Impact - Pro and open-source package test file changes will now correctly trigger CI - Package configuration changes will trigger appropriate test suites - Prevents false-positive "docs-only" detection that was blocking the latest master commit - The ensure-master-docs-safety mechanism will work properly with correct change detection 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Improved build system detection for JavaScript and TypeScript file changes to ensure accurate identification of code-related modifications. <sub>✏️ Tip: You can customize this high-level summary in your review settings.</sub> <!-- end of auto-generated comment: release notes by coderabbit.ai --> Co-authored-by: Claude <[email protected]>
Summary
Remove this paragraph and provide a general description of the code changes in your pull
request... were there any bugs you had fixed? If so, mention them. If
these bugs have open GitHub issues, be sure to tag them here as well,
to keep the conversation linked together.
Pull Request checklist
Remove this line after checking all the items here. If the item is not applicable to the PR, both check it out and wrap it by
~.Add the CHANGELOG entry at the top of the file.
Other Information
Remove this paragraph and mention any other important and relevant information such as benchmarks.
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.