Sha256: 6360c7eaa743f031249dfd9fbcd9e2f0116ceb01eeac987ad4e0d1ed7cdd81e5
Contents?: true
Size: 516 Bytes
Versions: 5
Compression:
Stored size: 516 Bytes
Contents
# frozen_string_literal: true require 'test_helper' class ForTagUnitTest < Minitest::Test def test_for_nodelist template = Liquid::Template.parse('{% for item in items %}FOR{% endfor %}') assert_equal(['FOR'], template.root.nodelist[0].nodelist.map(&:nodelist).flatten) end def test_for_else_nodelist template = Liquid::Template.parse('{% for item in items %}FOR{% else %}ELSE{% endfor %}') assert_equal(['FOR', 'ELSE'], template.root.nodelist[0].nodelist.map(&:nodelist).flatten) end end
Version data entries
5 entries across 5 versions & 1 rubygems