Sha256: c920467d8fc48489d7cb42709e756743e1ce5a86e51c577fb3ce851afc6f405e

Contents?: true

Size: 624 Bytes

Versions: 11

Compression:

Stored size: 624 Bytes

Contents

require 'test_helper'

class TagUnitTest < Minitest::Test
  include Liquid

  def test_tag
    tag = Tag.parse('tag', "", Tokenizer.new(""), ParseContext.new)
    assert_equal 'liquid::tag', tag.name
    assert_equal '', tag.render(Context.new)
  end

  def test_return_raw_text_of_tag
    tag = Tag.parse("long_tag", "param1, param2, param3", Tokenizer.new(""), ParseContext.new)
    assert_equal("long_tag param1, param2, param3", tag.raw)
  end

  def test_tag_name_should_return_name_of_the_tag
    tag = Tag.parse("some_tag", "", Tokenizer.new(""), ParseContext.new)
    assert_equal 'some_tag', tag.tag_name
  end
end

Version data entries

11 entries across 11 versions & 3 rubygems

Version Path
liquid-4.0.4 test/unit/tag_unit_test.rb
metanorma-cli-1.3.4 gems/ruby/2.6.0/gems/liquid-4.0.3/test/unit/tag_unit_test.rb
metanorma-cli-1.3.3.1 gems/ruby/2.6.0/gems/liquid-4.0.3/test/unit/tag_unit_test.rb
liquid-4.0.3 test/unit/tag_unit_test.rb
liquid-4.0.2 test/unit/tag_unit_test.rb
liquid-4-0-2-4.0.2 test/unit/tag_unit_test.rb
liquid-4.0.1 test/unit/tag_unit_test.rb
liquid-4.0.0 test/unit/tag_unit_test.rb
liquid-4.0.0.rc3 test/unit/tag_unit_test.rb
liquid-4.0.0.rc2 test/unit/tag_unit_test.rb
liquid-4.0.0.rc1 test/unit/tag_unit_test.rb