Sha256: 0b37a2b1bfa56f3cc1a0e8c9c25eb5f72dd4618b5123fb9fe6c90862c4932638

Contents?: true

Size: 311 Bytes

Versions: 15

Compression:

Stored size: 311 Bytes

Contents

require 'test_helper'

class CaseTagUnitTest < Minitest::Test
  include Liquid

  def test_case_nodelist
    template = Liquid::Template.parse('{% case var %}{% when true %}WHEN{% else %}ELSE{% endcase %}')
    assert_equal ['WHEN', 'ELSE'], template.root.nodelist[0].nodelist.map(&:nodelist).flatten
  end
end

Version data entries

15 entries across 15 versions & 4 rubygems

Version Path
liquid-4.0.4 test/unit/tags/case_tag_unit_test.rb
metanorma-cli-1.3.4 gems/ruby/2.6.0/gems/liquid-4.0.3/test/unit/tags/case_tag_unit_test.rb
metanorma-cli-1.3.3.1 gems/ruby/2.6.0/gems/liquid-4.0.3/test/unit/tags/case_tag_unit_test.rb
liquid-4.0.3 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.2 test/unit/tags/case_tag_unit_test.rb
liquid-4-0-2-4.0.2 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.1 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.0 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.0.rc3 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.0.rc2 test/unit/tags/case_tag_unit_test.rb
liquid-4.0.0.rc1 test/unit/tags/case_tag_unit_test.rb
locomotivecms-liquid-4.0.0 test/unit/tags/case_tag_unit_test.rb
locomotivecms-liquid-4.0.0.alpha2 test/unit/tags/case_tag_unit_test.rb
locomotivecms-liquid-4.0.0.alpha1 test/unit/tags/case_tag_unit_test.rb
locomotivecms-liquid-4.0.0.alpha test/unit/tags/case_tag_unit_test.rb