Skip to content

Commit

Permalink
Handle case where erubi/erubis is not installed in the specs
Browse files Browse the repository at this point in the history
ERB will omit the newline after the header, where erubi and erubis
will not.
  • Loading branch information
jeremyevans committed May 25, 2023
1 parent c04bf24 commit 58c6e89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions spec/plugin/render_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -181,9 +181,9 @@
end
end

body.gsub(/\n+/, "\n").must_equal "Header\n1\nFooter\n"
body.gsub(/\n+/, "\n").sub("\nFooter", 'Footer').must_equal "Header\n1Footer\n"
app.plugin :render, :layout=>'layout-yield2'
body.gsub(/\n+/, "\n").must_equal "Header2\n1\nFooter2\n"
body.gsub(/\n+/, "\n").sub("\nFooter", 'Footer').must_equal "Header2\n1Footer2\n"
end

it "should have :layout_opts=>:views plugin option respect :root app option" do
Expand Down

0 comments on commit 58c6e89

Please sign in to comment.