Skip to content

Bugfix: Fix mapping expression to handle omitted key #129

Bugfix: Fix mapping expression to handle omitted key

Bugfix: Fix mapping expression to handle omitted key #129

Triggered via pull request August 17, 2024 02:39
Status Failure
Total duration 24s
Artifacts

ci.yaml

on: pull_request
Matrix: Test
Fit to window
Zoom out
Zoom in

Annotations

4 errors
tests/Expressions/jsfmt.spec.js > Expressions > should handle mapping expressions: src/melody/melody-parser/TokenStream.js#L129
Error: ERROR: Invalid Token 10 | 11 | {# keys can be omitted if it is the same as the variable name #} > 12 | {% set foo = { foo } %} | ^ 13 | 14 | {% set foobar = { foo, bar } %} 15 | {# is equivalent to the following #} Expected : but found } instead. ❯ TokenStream.error src/melody/melody-parser/TokenStream.js:129:24 ❯ TokenStream.expect src/melody/melody-parser/TokenStream.js:103:14 ❯ Parser.matchMapping src/melody/melody-parser/Parser.js:784:20 ❯ Parser.matchPrimaryExpression src/melody/melody-parser/Parser.js:628:33 ❯ Parser.getPrimary src/melody/melody-parser/Parser.js:582:21 ❯ Parser.matchExpression src/melody/melody-parser/Parser.js:523:25 ❯ Object.parse src/melody/melody-extension-core/parser/set.js:44:36 ❯ Parser.matchTag src/melody/melody-parser/Parser.js:494:31 ❯ Parser.parse src/melody/melody-parser/Parser.js:173:32 ❯ Object.parse src/parser.js:82:24
Test (20)
Process completed with exit code 1.
tests/Expressions/jsfmt.spec.js > Expressions > should handle mapping expressions: src/melody/melody-parser/TokenStream.js#L129
Error: ERROR: Invalid Token 10 | 11 | {# keys can be omitted if it is the same as the variable name #} > 12 | {% set foo = { foo } %} | ^ 13 | 14 | {% set foobar = { foo, bar } %} 15 | {# is equivalent to the following #} Expected : but found } instead. ❯ TokenStream.error src/melody/melody-parser/TokenStream.js:129:24 ❯ TokenStream.expect src/melody/melody-parser/TokenStream.js:103:14 ❯ Parser.matchMapping src/melody/melody-parser/Parser.js:784:20 ❯ Parser.matchPrimaryExpression src/melody/melody-parser/Parser.js:628:33 ❯ Parser.getPrimary src/melody/melody-parser/Parser.js:582:21 ❯ Parser.matchExpression src/melody/melody-parser/Parser.js:523:25 ❯ Object.parse src/melody/melody-extension-core/parser/set.js:44:36 ❯ Parser.matchTag src/melody/melody-parser/Parser.js:494:31 ❯ Parser.parse src/melody/melody-parser/Parser.js:173:32 ❯ Object.parse src/parser.js:82:24
Test (18)
Process completed with exit code 1.