Sha256: aef124c1bcbcd19018e513a5b037ace13db8ef40111daec55c87e2a8895e21de

Contents?: true

Size: 447 Bytes

Versions: 41

Compression:

Stored size: 447 Bytes

Contents

require 'spec_helper'

RSpec.describe 'Haml comment rendering', type: :render do
  it 'renders nothing' do
    expect(render_string(<<HAML)).to eq("<div>\n<p>hello</p>\n<p>world</p>\n</div>\n")
%div
  %p hello
  -# this
      should
    not
      be rendered
  %p world
HAML
  end

  it 'parses empty comment' do
    expect(render_string(<<HAML)).to eq("<div>\n<p>hello</p>\n<p>world</p>\n</div>\n")
%div
  %p hello
  -#
  %p world
HAML
  end
end

Version data entries

41 entries across 41 versions & 2 rubygems

Version Path
faml-0.6.0 spec/render/haml_comment_spec.rb
faml-0.5.1 spec/render/haml_comment_spec.rb
faml-0.5.0 spec/render/haml_comment_spec.rb
faml-0.4.2 spec/render/haml_comment_spec.rb
faml-0.4.1 spec/render/haml_comment_spec.rb
faml-0.4.0 spec/render/haml_comment_spec.rb
faml-0.3.6 spec/render/haml_comment_spec.rb
faml-0.3.5 spec/render/haml_comment_spec.rb
faml-0.3.4 spec/render/haml_comment_spec.rb
faml-0.3.3 spec/render/haml_comment_spec.rb
faml-0.3.2 spec/render/haml_comment_spec.rb
faml-0.3.1 spec/render/haml_comment_spec.rb
faml-0.3.0 spec/render/haml_comment_spec.rb
faml-0.2.16 spec/render/haml_comment_spec.rb
faml-0.2.15 spec/render/haml_comment_spec.rb
faml-0.2.14 spec/render/haml_comment_spec.rb
faml-0.2.13 spec/render/haml_comment_spec.rb
faml-0.2.12 spec/render/haml_comment_spec.rb
faml-0.2.11 spec/render/haml_comment_spec.rb
faml-0.2.10 spec/render/haml_comment_spec.rb