Fixed lax parsing test case

This commit is contained in:
Albert Chu
2025-03-13 10:53:24 -06:00
parent 484f016e1b
commit e6e8221c78
2 changed files with 17 additions and 10 deletions
@@ -3,6 +3,9 @@
module Liquid
class Expression
class ComparisonExpression
# We can improve the resiliency of lax parsing by not expecting whitespace
# surrounding the operator (ie \s+ => \s*).
# However this is not in parity with existing lax parsing behavior.
COMPARISON_REGEX = /\A\s*(.+?)\s+(==|!=|<>|<=|>=|<|>|contains)\s+(.+)\s*\z/
class << self