Sha256: ef7efd6b37476fb6db07158bebf62082d473d9a052b110e45eac80cf70533b7e

Contents?: true

Size: 721 Bytes

Versions: 15

Compression:

Stored size: 721 Bytes

Contents

# -*- encoding: utf-8 -*-

require 'webgen/test_helper'

class TestScss < Minitest::Test

  include Webgen::TestHelper

  def test_static_call
    require 'webgen/content_processor/scss' rescue skip('Library sass not installed')
    setup_context
    @website.config['content_processor.sass.options'] = {}
    @website.ext.sass_load_paths = []
    cp = Webgen::ContentProcessor::Scss

    @context.content = "#main {background-color: #000}"
    assert_equal("#main {\n  background-color: #000; }\n", cp.call(@context).content)

    @context.content = "#cont\n = 5"
    assert_error_on_line(Webgen::RenderError, 2) { cp.call(@context) }
  end

  def teardown
    FileUtils.rm_rf(@website.directory) if @website
  end

end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
webgen-1.7.3 test/webgen/content_processor/test_scss.rb
webgen-1.7.2 test/webgen/content_processor/test_scss.rb
webgen-1.7.1 test/webgen/content_processor/test_scss.rb
webgen-1.7.0 test/webgen/content_processor/test_scss.rb
webgen-1.6.0 test/webgen/content_processor/test_scss.rb
webgen-1.5.2 test/webgen/content_processor/test_scss.rb
webgen-1.5.1 test/webgen/content_processor/test_scss.rb
webgen-1.5.0 test/webgen/content_processor/test_scss.rb
webgen-1.4.1 test/webgen/content_processor/test_scss.rb
webgen-1.4.0 test/webgen/content_processor/test_scss.rb
webgen-1.3.0 test/webgen/content_processor/test_scss.rb
webgen-1.2.1 test/webgen/content_processor/test_scss.rb
webgen-1.2.0 test/webgen/content_processor/test_scss.rb
webgen-1.1.0 test/webgen/content_processor/test_scss.rb
webgen-1.0.0 test/webgen/content_processor/test_scss.rb