Przeglądaj źródła

Added a test (not working yet)

Chimrod 5 miesięcy temu
rodzic
commit
57330137ce
1 zmienionych plików z 4 dodań i 0 usunięć
  1. 4 0
      test/syntax.ml

+ 4 - 0
test/syntax.ml

@@ -882,6 +882,9 @@ let test_stattxt () =
             { Tree.Ast.pos = _position; name = "$STATTXT"; index = None } );
     ]
 
+let test_for_end () = _test_instruction {|for a = 1 to 10:
+end|} []
+
 let test =
   ( "Syntax",
     [
@@ -951,4 +954,5 @@ let test =
       Alcotest.test_case "Precedence7" `Quick test_precedence7;
       Alcotest.test_case "Precedence8" `Quick test_precedence8;
       Alcotest.test_case "stattxt" `Quick test_stattxt;
+      Alcotest.test_case "for ... end" `Quick test_for_end;
     ] )