You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I believe the tests are setup correctly. The issue lies in how the ESLint rules are executed. According to the documentation, after the fix is applied, it will run the rule (apply the fix) on the fixed code again and again until there is no diff between the files (no potential changes to fix) or until the rule runs 10 timeshttps://eslint.org/docs/latest/extend/custom-rules#applying-fixes.
The ESLint tests apply the fix only once. In case of nested components, I believe it is treated as a range conflict, so only one component can be renamed while applying the fix.
This means that #675 (text to content codemod) will not work for case where some element is nested more than 10 times, e.g. some deeply nested list items.
Follow up to #675
In order to land #675 I commented out some tests that were failing because of an issue with our test setup.
Nested test components are not updated in the unit tests, but are properly handled by the codemod in the real world.
Ideally we should dig into why we run into these false negative tests, and resolve the issue.
Additionally we should expand the text-replace-with-content test suite with coverage for alternative imports, aliasing, etc.
The text was updated successfully, but these errors were encountered: