Sha256: ee3d16d12fe35a1a3a92fb7d14ffb3742d3cfaca163974ddc65dbc76ca03e954

Contents?: true

Size: 553 Bytes

Versions: 15

Compression:

Stored size: 553 Bytes

Contents

# encoding: utf-8

class Nanoc::Filters::TypogrubyTest < Nanoc::TestCase

  def test_filter
    if_have 'typogruby' do
      # Get filter
      filter = ::Nanoc::Filters::Typogruby.new

      # Run filter
      a = '"Typogruby makes HTML look smarter &amp; better, don\'t you think?"'
      b = '<span class="dquo">&#8220;</span>Typogruby makes <span class="caps">HTML</span> look smarter <span class="amp">&amp;</span> better, don&#8217;t you&nbsp;think?&#8221;'
      result = filter.setup_and_run(a)
      assert_equal(b, result)
    end
  end

end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
nanoc-3.7.4 test/filters/test_typogruby.rb
nanoc-3.7.3 test/filters/test_typogruby.rb
nanoc-3.7.2 test/filters/test_typogruby.rb
nanoc-3.7.1 test/filters/test_typogruby.rb
nanoc-3.7.0 test/filters/test_typogruby.rb
nanoc-3.6.11 test/filters/test_typogruby.rb
nanoc-3.6.10 test/filters/test_typogruby.rb
nanoc-3.6.9 test/filters/test_typogruby.rb
nanoc-3.6.8 test/filters/test_typogruby.rb
nanoc-3.6.7 test/filters/test_typogruby.rb
nanoc-3.6.6 test/filters/test_typogruby.rb
nanoc-3.6.5 test/filters/test_typogruby.rb
nanoc-3.6.4 test/filters/test_typogruby.rb
nanoc-3.6.3 test/filters/test_typogruby.rb
nanoc-3.6.2 test/filters/test_typogruby.rb