Skip to content
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

[v4.3] Fix unsafe html view component, allow ViewComponent 3.21+ #6071

Merged
merged 1 commit into from
Jan 15, 2025

Conversation

tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Jan 15, 2025

Backport

This will backport the following commits from main to v4.3:

Questions ?

Please refer to the Backport tool documentation

@tvdeyen tvdeyen requested a review from a team as a code owner January 15, 2025 16:18
@tvdeyen tvdeyen added backport-v4.1 Backport this pull-request to v4.1 backport-v4.2 Backport this pull-request to v4.2 backport-v4.3 Backport this pull-request to v4.3 backport-v4.4 Backport this pull-request to v4.4 changelog:solidus_admin labels Jan 15, 2025
@tvdeyen tvdeyen removed backport-v4.1 Backport this pull-request to v4.1 backport-v4.2 Backport this pull-request to v4.2 backport-v4.3 Backport this pull-request to v4.3 backport-v4.4 Backport this pull-request to v4.4 labels Jan 15, 2025
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.

(cherry picked from commit 228ca12)

# Conflicts:
#	admin/lib/solidus_admin/testing_support/component_helpers.rb
#	admin/spec/components/solidus_admin/base_component_spec.rb
@tvdeyen
Copy link
Member Author

tvdeyen commented Jan 15, 2025

Flaky unrelated specs. Need this for #6070

@tvdeyen tvdeyen merged commit d97e4e9 into v4.3 Jan 15, 2025
10 of 11 checks passed
@tvdeyen tvdeyen deleted the backport/v4.3/pr-6055 branch January 15, 2025 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants