Skip to content

Testing "nested components" #877

Closed Answered by MatheusRich
MatheusRich asked this question in Q&A
Discussion options

You must be logged in to vote

Just include some modules (you'll have to tweak a bit because I don't remember exactly which ones are necessary)

RSpec.describe My::Component, type: :component do
  include ActionView::Context
  include ActionView::Helpers::FormHelper
  include Rails.application.routes.url_helpers

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@MatheusRich
Comment options

Answer selected by joelhawksley
@edouard-per-angusta
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants