Sha256: b6fb14514f80addbdadb9ea163d75a2da31199b9250b3a149d24f6e82b9f3230

Contents?: true

Size: 627 Bytes

Versions: 10

Compression:

Stored size: 627 Bytes

Contents

require 'spec_helper'

RSpec.describe 'SCSS filter rendering', type: :render do
  it 'renders SCSS filter' do
    html = render_string(<<'HAML')
:scss
  nav {
    ul {
      margin: 0;
      content: "hello";
    }
  }
HAML
    expect(html).to include('<style>')
    expect(html).to include('nav ul {')
    expect(html).to include('content: "hello"')
  end

  it 'parses string interpolation' do
    html = render_string(<<'HAML')
:scss
  nav {
    ul {
      margin: #{0 + 5}px;
    }
  }
HAML
    expect(html).to include('<style>')
    expect(html).to include('nav ul {')
    expect(html).to include('margin: 5px')
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
faml-0.6.0 spec/render/filters/scss_spec.rb
faml-0.5.1 spec/render/filters/scss_spec.rb
faml-0.5.0 spec/render/filters/scss_spec.rb
faml-0.4.2 spec/render/filters/scss_spec.rb
faml-0.4.1 spec/render/filters/scss_spec.rb
faml-0.4.0 spec/render/filters/scss_spec.rb
faml-0.3.6 spec/render/filters/scss_spec.rb
faml-0.3.5 spec/render/filters/scss_spec.rb
faml-0.3.4 spec/render/filters/scss_spec.rb
faml-0.3.3 spec/render/filters/scss_spec.rb