don't add comment node to the nodelist

This commit is contained in:
Michael Go
2025-01-07 14:08:45 -04:00
parent b4667adadf
commit 879ec3e288
4 changed files with 32 additions and 4 deletions
+2 -2
View File
@@ -49,8 +49,8 @@ class BlockUnitTest < Minitest::Test
def test_with_block
template = Liquid::Template.parse(" {% comment %} {% endcomment %} ")
assert_equal([String, Comment, String], block_types(template.root.nodelist))
assert_equal(3, template.root.nodelist.size)
assert_equal([String, String], block_types(template.root.nodelist))
assert_equal(2, template.root.nodelist.size)
end
private