Sha256: 23ce3c0d5cf8b69af7b4b0004e7f6e5ce62ed76a7e356efde97f42d4892f1a20

Contents?: true

Size: 796 Bytes

Versions: 102

Compression:

Stored size: 796 Bytes

Contents

require 'helper'


class TestSlimWrapper < TestSlim
  def setup
    Slim::Sections.set_default_options(:dictionary => 'ViewEnv.new')
  end

  def teardown
    Slim::Sections.set_default_options(:dictionary => 'self')
  end

  def test_sections
    source = %q{
p
 - person
  .name = name
}
    assert_html '<p><div class="name">Joe</div><div class="name">Jack</div></p>', source, :sections => true
  end

  def test_with_array
    source = %q{
ul
 - people_with_locations
  li = name
  li = city
}
    assert_html '<ul><li>Andy</li><li>Atlanta</li><li>Fred</li><li>Melbourne</li><li>Daniel</li><li>Karlsruhe</li></ul>', source, :sections => true
  end

  def test_method
    source = %q{
a href=output_number Link
}
    assert_html '<a href="1337">Link</a>', source, :sections => true
  end

end

Version data entries

102 entries across 57 versions & 2 rubygems

Version Path
classiccms-0.5.13 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.13 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.12 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.12 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.11 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.11 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.10 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.10 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.9 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.9 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.8 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.8 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.7 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.7 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.6 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.6 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.5 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.5 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb
classiccms-0.5.2 vendor/bundle/gems/slim-1.2.0/test/slim/test_wrapper.rb
classiccms-0.5.2 vendor/bundle/gems/slim-1.2.1/test/slim/test_wrapper.rb