-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Fix unsafe html view component, allow ViewComponent 3.21+ #6055
Fix unsafe html view component, allow ViewComponent 3.21+ #6055
Conversation
The mock component in the ComponentHelpers module was not a real constant, which messes with ViewComponent's expectations about what render_inline is given. Using `stub_const` in the helper allows us to give it an actual name, and view_component > 3.21.0 will work for us. The helper is only used in the base component spec. I could have spent more time giving it an optional block, but this solution is the most straightforward.
4411534
to
7bd0860
Compare
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation and see the Github Action logs for details |
Summary
This fixes the
mock_component
helper to always mock an actual constant, rather than just stubbing the name on it. view_component expects components to be actual things.Checklist
Check out our PR guidelines for more details.
The following are mandatory for all PRs:
The following are not always needed: