mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-15 08:50:45 -07:00
Revert "Merge pull request #463 from Shopify/stricter-identifiers"
This reverts commita056f6521c, reversing changes made to7843bcca8d.
This commit is contained in:
@@ -31,8 +31,8 @@ class LexerUnitTest < Minitest::Test
|
||||
end
|
||||
|
||||
def test_fancy_identifiers
|
||||
tokens = Lexer.new('hi five?').tokenize
|
||||
assert_equal [[:id,'hi'], [:id, 'five'], [:question, '?'], [:end_of_string]], tokens
|
||||
tokens = Lexer.new('hi! five?').tokenize
|
||||
assert_equal [[:id,'hi!'], [:id, 'five?'], [:end_of_string]], tokens
|
||||
end
|
||||
|
||||
def test_whitespace
|
||||
|
||||
@@ -44,9 +44,9 @@ class ParserUnitTest < Minitest::Test
|
||||
end
|
||||
|
||||
def test_expressions
|
||||
p = Parser.new("hi.there hi?[5].there? hi.there.bob")
|
||||
p = Parser.new("hi.there hi[5].! hi.there.bob")
|
||||
assert_equal 'hi.there', p.expression
|
||||
assert_equal 'hi?[5].there?', p.expression
|
||||
assert_equal 'hi[5].!', p.expression
|
||||
assert_equal 'hi.there.bob', p.expression
|
||||
|
||||
p = Parser.new("567 6.0 'lol' \"wut\"")
|
||||
|
||||
Reference in New Issue
Block a user