mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-19 10:52:48 -07:00
Disallow number and dash identifier prefixes
This commit is contained in:
@@ -32,7 +32,10 @@ class LexerUnitTest < Minitest::Test
|
||||
|
||||
def test_fancy_identifiers
|
||||
tokens = Lexer.new('hi five?').tokenize
|
||||
assert_equal [[:id,'hi'], [:id, 'five?'], [:end_of_string]], tokens
|
||||
assert_equal [[:id, 'hi'], [:id, 'five?'], [:end_of_string]], tokens
|
||||
|
||||
tokens = Lexer.new('2foo').tokenize
|
||||
assert_equal [[:number, '2'], [:id, 'foo'], [:end_of_string]], tokens
|
||||
end
|
||||
|
||||
def test_whitespace
|
||||
|
||||
Reference in New Issue
Block a user