diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/literals.ml | 38 | ||||
-rw-r--r-- | test/syntax_error.ml | 6 |
2 files changed, 19 insertions, 25 deletions
diff --git a/test/literals.ml b/test/literals.ml index 6070f86..8f5a56e 100644 --- a/test/literals.ml +++ b/test/literals.ml @@ -13,7 +13,7 @@ let result = (Tree.Ast.Literal ( _position, [ - T.Expression [ Tree.Ast.Literal (_position, [ T.Text "key" ]) ]; + T.Expression (Tree.Ast.Literal (_position, [ T.Text "key" ])); T.Text ""; ] )); ] @@ -71,25 +71,23 @@ let expression () = ( _position, [ T.Expression - [ - Tree.Ast.Function - ( _position, - T.Iif, - [ - Tree.Ast.BinaryOp - ( _position, - T.Eq, - Tree.Ast.Ident - { - Tree.Ast.pos = _position; - name = "VAR"; - index = None; - }, - Tree.Ast.Integer (_position, "0") ); - Tree.Ast.Integer (_position, "1"); - Tree.Ast.Integer (_position, "0"); - ] ); - ]; + (Tree.Ast.Function + ( _position, + T.Iif, + [ + Tree.Ast.BinaryOp + ( _position, + T.Eq, + Tree.Ast.Ident + { + Tree.Ast.pos = _position; + name = "VAR"; + index = None; + }, + Tree.Ast.Integer (_position, "0") ); + Tree.Ast.Integer (_position, "1"); + Tree.Ast.Integer (_position, "0"); + ] )); T.Text ""; ] )); ] diff --git a/test/syntax_error.ml b/test/syntax_error.ml index b56d3f2..08de384 100644 --- a/test/syntax_error.ml +++ b/test/syntax_error.ml @@ -106,11 +106,7 @@ let missing_operand () = let unknow_function () = _test_instruction "a = ran(1, 2)" - { - level = Error; - loc = _position; - message = "Missing separator between instructions"; - } + { level = Error; loc = _position; message = "Unexpected expression here." } let inline_elif () = _test_instruction {| |