From: Siraaj Khandkar Date: Thu, 24 May 2018 01:27:53 +0000 (-0400) Subject: Use meaningful names of test cases X-Git-Url: https://git.xandkar.net/?a=commitdiff_plain;h=19284c5d9514bf59f24607e620056db778a4372b;p=tiger.ml.git Use meaningful names of test cases --- diff --git a/tiger/src/exe/tiger_tests.ml b/tiger/src/exe/tiger_tests.ml index 64eb01b..e222599 100644 --- a/tiger/src/exe/tiger_tests.ml +++ b/tiger/src/exe/tiger_tests.ml @@ -1,9 +1,10 @@ module List = ListLabels let test_01 = + let name = "an array type and an array variable" in let code = " \ - /* an array type and an array variable */ \ + /* "^name^" */ \ let \ type arrtype = array of int \ var arr1:arrtype := \ @@ -24,12 +25,13 @@ let test_01 = END ] in - ("test_01", code, tokens) + (name, code, tokens) let test_02 = + let name = "arr1 is valid since expression 0 is int = myint" in let code = " \ - /* arr1 is valid since expression 0 is int = myint */ \ + /* "^name^" */ \ let \ type myint = int \ type arrtype = array of myint \ @@ -52,12 +54,13 @@ let test_02 = END ] in - ("test_02", code, tokens) + (name, code, tokens) let test_03 = + let name = "a record type and a record variable" in let code = " \ - /* a record type and a record variable */ \ + /* "^name^" */ \ let \ type rectype = \ { name : string \ @@ -92,7 +95,7 @@ let test_03 = END ] in - ("test_03", code, tokens) + (name, code, tokens) let test_04 = let name = "define a recursive function" in