Update twig.test.ts

pull/4063/head
claylibrarymarket 2023-07-07 10:07:41 -05:00 committed by GitHub
parent de76be4e6c
commit e1e946ac65
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 33 additions and 0 deletions

View File

@ -734,6 +734,15 @@ testTokenization(
tokens: [{ startIndex: 0, type: 'comment.twig' }]
}
],
[
{
line: 'test {# Hello World! #}',
tokens: [
{ startIndex: 0, type: '' },
{ startIndex: 5, type: 'comment.twig' }
]
}
],
[
{
line: '{#Hello World!#}',
@ -860,6 +869,19 @@ testTokenization(
]
}
],
[
{
line: 'test {{ foo }}',
tokens: [
{ startIndex: 0, type: '' },
{ startIndex: 5, type: 'delimiter.twig' },
{ startIndex: 7, type: '' },
{ startIndex: 8, type: 'variable.twig' },
{ startIndex: 11, type: '' },
{ startIndex: 12, type: 'delimiter.twig' }
]
}
],
[
{
line: '{{ foo(42) }}',
@ -962,6 +984,17 @@ testTokenization(
]
}
],
[
{
line: 'test {% %}',
tokens: [
{ startIndex: 0, type: '' },
{ startIndex: 5, type: 'delimiter.twig' },
{ startIndex: 7, type: '' },
{ startIndex: 8, type: 'delimiter.twig' }
]
}
],
[
{
line: '{% for item in navigation %}',