Skip to content

Commit b9c0c5b

Browse files
Update tests to expect HTML comments instead of script tags for React components
1 parent b63a704 commit b9c0c5b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spec/dummy/spec/helpers/react_on_rails_helper_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ def helper.append_javascript_pack_tag(name, **options)
258258
it { expect(self).to respond_to :react_component }
259259

260260
it { is_expected.to be_an_instance_of ActiveSupport::SafeBuffer }
261-
it { is_expected.to start_with "<script" }
261+
it { is_expected.to start_with "<!--" }
262262
it { is_expected.to match %r{</script>\s*$} }
263263
it { is_expected.to include react_component_div }
264264

@@ -536,7 +536,7 @@ def helper.append_javascript_pack_tag(name, **options)
536536
it { expect(self).to respond_to :redux_store }
537537

538538
it { is_expected.to be_an_instance_of ActiveSupport::SafeBuffer }
539-
it { is_expected.to start_with "<script" }
539+
it { is_expected.to start_with "<!--" }
540540
it { is_expected.to end_with "</script>" }
541541

542542
it {

0 commit comments

Comments
 (0)