jaclang 0.7.14__py3-none-any.whl → 0.7.17__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of jaclang might be problematic. Click here for more details.

Files changed (131) hide show
  1. jaclang/cli/cli.py +147 -77
  2. jaclang/cli/cmdreg.py +9 -12
  3. jaclang/compiler/__init__.py +19 -53
  4. jaclang/compiler/absyntree.py +94 -16
  5. jaclang/compiler/constant.py +8 -8
  6. jaclang/compiler/jac.lark +4 -3
  7. jaclang/compiler/parser.py +41 -25
  8. jaclang/compiler/passes/ir_pass.py +4 -13
  9. jaclang/compiler/passes/main/__init__.py +1 -1
  10. jaclang/compiler/passes/main/access_modifier_pass.py +96 -147
  11. jaclang/compiler/passes/main/fuse_typeinfo_pass.py +155 -54
  12. jaclang/compiler/passes/main/import_pass.py +99 -75
  13. jaclang/compiler/passes/main/py_collect_dep_pass.py +70 -0
  14. jaclang/compiler/passes/main/pyast_gen_pass.py +328 -565
  15. jaclang/compiler/passes/main/pyast_load_pass.py +33 -6
  16. jaclang/compiler/passes/main/pyjac_ast_link_pass.py +7 -0
  17. jaclang/compiler/passes/main/registry_pass.py +37 -3
  18. jaclang/compiler/passes/main/schedules.py +9 -2
  19. jaclang/compiler/passes/main/sym_tab_build_pass.py +10 -6
  20. jaclang/compiler/passes/main/tests/__init__.py +1 -1
  21. jaclang/compiler/passes/main/tests/fixtures/autoimpl.empty.impl.jac +0 -0
  22. jaclang/compiler/passes/main/tests/fixtures/autoimpl.jac +1 -1
  23. jaclang/compiler/passes/main/tests/fixtures/py_imp_test.jac +29 -0
  24. jaclang/compiler/passes/main/tests/fixtures/pygame_mock/__init__.py +3 -0
  25. jaclang/compiler/passes/main/tests/fixtures/pygame_mock/color.py +3 -0
  26. jaclang/compiler/passes/main/tests/fixtures/pygame_mock/constants.py +5 -0
  27. jaclang/compiler/passes/main/tests/fixtures/pygame_mock/display.py +2 -0
  28. jaclang/compiler/passes/main/tests/test_import_pass.py +72 -13
  29. jaclang/compiler/passes/main/type_check_pass.py +22 -5
  30. jaclang/compiler/passes/tool/jac_formatter_pass.py +135 -89
  31. jaclang/compiler/passes/tool/tests/fixtures/corelib.jac +37 -41
  32. jaclang/compiler/passes/tool/tests/fixtures/corelib_fmt.jac +37 -42
  33. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/access_mod_check.jac +27 -0
  34. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/architype_test.jac +13 -0
  35. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/comment_alignment.jac +11 -0
  36. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/comments.jac +13 -0
  37. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/decorator_stack.jac +37 -0
  38. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/esc_keywords.jac +5 -0
  39. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/long_names.jac +19 -0
  40. jaclang/compiler/passes/tool/tests/fixtures/general_format_checks/triple_quoted_string.jac +6 -0
  41. jaclang/compiler/passes/tool/tests/test_jac_format_pass.py +11 -0
  42. jaclang/compiler/passes/tool/tests/test_unparse_validate.py +33 -39
  43. jaclang/compiler/passes/transform.py +4 -0
  44. jaclang/compiler/passes/utils/mypy_ast_build.py +45 -0
  45. jaclang/compiler/semtable.py +31 -7
  46. jaclang/compiler/symtable.py +16 -11
  47. jaclang/compiler/tests/test_importer.py +25 -10
  48. jaclang/langserve/engine.py +104 -118
  49. jaclang/langserve/sem_manager.py +379 -0
  50. jaclang/langserve/server.py +24 -11
  51. jaclang/langserve/tests/fixtures/base_module_structure.jac +27 -6
  52. jaclang/langserve/tests/fixtures/circle.jac +3 -3
  53. jaclang/langserve/tests/fixtures/circle_err.jac +3 -3
  54. jaclang/langserve/tests/fixtures/circle_pure.test.jac +3 -3
  55. jaclang/langserve/tests/fixtures/import_include_statements.jac +1 -1
  56. jaclang/langserve/tests/fixtures/rename.jac +30 -0
  57. jaclang/langserve/tests/test_sem_tokens.py +277 -0
  58. jaclang/langserve/tests/test_server.py +287 -17
  59. jaclang/langserve/utils.py +184 -98
  60. jaclang/plugin/builtin.py +1 -1
  61. jaclang/plugin/default.py +288 -92
  62. jaclang/plugin/feature.py +65 -27
  63. jaclang/plugin/spec.py +62 -23
  64. jaclang/plugin/tests/fixtures/other_root_access.jac +82 -0
  65. jaclang/plugin/tests/test_jaseci.py +414 -42
  66. jaclang/runtimelib/architype.py +650 -0
  67. jaclang/{core → runtimelib}/constructs.py +5 -8
  68. jaclang/{core → runtimelib}/context.py +86 -59
  69. jaclang/runtimelib/importer.py +361 -0
  70. jaclang/runtimelib/machine.py +158 -0
  71. jaclang/runtimelib/memory.py +158 -0
  72. jaclang/{core → runtimelib}/utils.py +30 -15
  73. jaclang/settings.py +5 -4
  74. jaclang/tests/fixtures/abc.jac +3 -3
  75. jaclang/tests/fixtures/access_checker.jac +12 -17
  76. jaclang/tests/fixtures/access_modifier.jac +88 -33
  77. jaclang/tests/fixtures/baddy.jac +3 -0
  78. jaclang/tests/fixtures/baddy.test.jac +3 -0
  79. jaclang/tests/fixtures/bar.jac +34 -0
  80. jaclang/tests/fixtures/byllmissue.jac +1 -5
  81. jaclang/tests/fixtures/chandra_bugs2.jac +11 -10
  82. jaclang/tests/fixtures/cls_method.jac +41 -0
  83. jaclang/tests/fixtures/dblhello.jac +6 -0
  84. jaclang/tests/fixtures/deep/one_lev.jac +3 -3
  85. jaclang/tests/fixtures/deep/one_lev_dup.jac +2 -3
  86. jaclang/tests/fixtures/deep_import_mods.jac +13 -0
  87. jaclang/tests/fixtures/edge_node_walk.jac +1 -1
  88. jaclang/tests/fixtures/edge_ops.jac +1 -1
  89. jaclang/tests/fixtures/edges_walk.jac +1 -1
  90. jaclang/tests/fixtures/err.impl.jac +3 -0
  91. jaclang/tests/fixtures/err.jac +4 -2
  92. jaclang/tests/fixtures/err_runtime.jac +15 -0
  93. jaclang/tests/fixtures/foo.jac +43 -0
  94. jaclang/tests/fixtures/gendot_bubble_sort.jac +1 -1
  95. jaclang/tests/fixtures/hello.jac +4 -0
  96. jaclang/tests/fixtures/impl_grab.impl.jac +2 -1
  97. jaclang/tests/fixtures/impl_grab.jac +4 -1
  98. jaclang/tests/fixtures/import.jac +9 -0
  99. jaclang/tests/fixtures/index_slice.jac +30 -0
  100. jaclang/tests/fixtures/jp_importer_auto.jac +14 -0
  101. jaclang/tests/fixtures/maxfail_run_test.jac +4 -4
  102. jaclang/tests/fixtures/needs_import.jac +2 -2
  103. jaclang/tests/fixtures/pyfunc_1.py +1 -1
  104. jaclang/tests/fixtures/pyfunc_2.py +5 -2
  105. jaclang/tests/fixtures/pygame_mock/__init__.py +3 -0
  106. jaclang/tests/fixtures/pygame_mock/color.py +3 -0
  107. jaclang/tests/fixtures/pygame_mock/constants.py +5 -0
  108. jaclang/tests/fixtures/pygame_mock/display.py +2 -0
  109. jaclang/tests/fixtures/pygame_mock/inner/__init__.py +0 -0
  110. jaclang/tests/fixtures/pygame_mock/inner/iner_mod.py +2 -0
  111. jaclang/tests/fixtures/registry.jac +9 -0
  112. jaclang/tests/fixtures/run_test.jac +4 -4
  113. jaclang/tests/fixtures/semstr.jac +1 -4
  114. jaclang/tests/fixtures/simple_archs.jac +1 -1
  115. jaclang/tests/test_cli.py +109 -3
  116. jaclang/tests/test_language.py +170 -68
  117. jaclang/tests/test_reference.py +2 -3
  118. jaclang/utils/helpers.py +45 -21
  119. jaclang/utils/test.py +9 -0
  120. jaclang/utils/treeprinter.py +30 -7
  121. {jaclang-0.7.14.dist-info → jaclang-0.7.17.dist-info}/METADATA +3 -2
  122. {jaclang-0.7.14.dist-info → jaclang-0.7.17.dist-info}/RECORD +126 -90
  123. jaclang/core/architype.py +0 -502
  124. jaclang/core/importer.py +0 -344
  125. jaclang/core/memory.py +0 -99
  126. jaclang/tests/fixtures/aott_raise.jac +0 -25
  127. jaclang/tests/fixtures/package_import.jac +0 -6
  128. /jaclang/{core → runtimelib}/__init__.py +0 -0
  129. /jaclang/{core → runtimelib}/test.py +0 -0
  130. {jaclang-0.7.14.dist-info → jaclang-0.7.17.dist-info}/WHEEL +0 -0
  131. {jaclang-0.7.14.dist-info → jaclang-0.7.17.dist-info}/entry_points.txt +0 -0
@@ -1,5 +1,7 @@
1
- """Demo"""
1
+ obj HasFault {
2
+ can init;
3
+ }
2
4
 
3
5
  can speak {
4
- "Hello" |> aprint;
6
+ HasFault();
5
7
  }
@@ -0,0 +1,15 @@
1
+
2
+ can bar(some_list:list) {
3
+ invalid_index = 4;
4
+ print(some_list[invalid_index]); # This should fail.
5
+ }
6
+
7
+
8
+ can foo() {
9
+ bar([0, 1, 2, 3]);
10
+ }
11
+
12
+
13
+ with entry {
14
+ foo();
15
+ }
@@ -0,0 +1,43 @@
1
+ import:py from jaclang.plugin.feature, JacFeature as Jac;
2
+ import:py from jaclang.runtimelib.machine, JacMachine;
3
+ import:jac from bar, bar_walk;
4
+ # Test runner to initialize the walker
5
+
6
+ can test_run {
7
+ # Print the loaded modules
8
+ modules = JacMachine.get().list_modules();
9
+ "Loaded Modules:" |> print;
10
+ for mod_name in modules {
11
+ f"Module: {mod_name}" |> print;
12
+ }
13
+ # Print walkers
14
+ walkers = JacMachine.get().list_walkers(mod_name);
15
+ if walkers {
16
+ f"Walkers in {mod_name}:" |> print;
17
+ for walker in walkers {
18
+ f" - Walker: {walker}" |> print;
19
+ }
20
+ }
21
+ # Print nodes
22
+ nodes = JacMachine.get().list_nodes(mod_name);
23
+ if nodes {
24
+ f"Nodes in {mod_name}:" |> print;
25
+ for node in nodes {
26
+ f" - Node: {node}" |> print;
27
+ }
28
+ }
29
+ # Print edges
30
+ edges = JacMachine.get().list_edges(mod_name);
31
+ if edges {
32
+ f"Edges in {mod_name}:" |> print;
33
+ for edge in edges {
34
+ f" - Edge: {edge}" |> print;
35
+ }
36
+ }
37
+ root spawn bar_walk();
38
+ }
39
+ # Define the entry point to run the test
40
+
41
+ with entry {
42
+ test_run();
43
+ }
@@ -73,5 +73,5 @@ with entry {
73
73
  root spawn walker1();
74
74
  root spawn walker2();
75
75
  root spawn walker3();
76
- print(root._jac_.gen_dot());
76
+ print(root.__jac__.gen_dot());
77
77
  }
@@ -1,5 +1,9 @@
1
1
  """Hello World!"""
2
2
 
3
+ can still_there {
4
+ print("im still here");
5
+ }
6
+
3
7
  with entry {
4
8
  "Hello World!" |> print;
5
9
  }
@@ -1,4 +1,5 @@
1
1
  import:py math;
2
+
2
3
  :can:test_grab {
3
4
  return math.sqrt(2);
4
- }
5
+ }
@@ -1,2 +1,5 @@
1
1
  can test_grab;
2
- with entry {print(test_grab());}
2
+
3
+ with entry {
4
+ print(test_grab());
5
+ }
@@ -0,0 +1,9 @@
1
+ import:py os;
2
+ import:py sys;
3
+ import:py pyfunc;
4
+ import:py pygame_mock.inner;
5
+ import:py pygame_mock.inner.inner_mod;
6
+ import:py math;
7
+ import:py argparse;
8
+ import:py from pygame_mock { color, display }
9
+ import:py pygame_mock;
@@ -0,0 +1,30 @@
1
+ obj fruit {
2
+ has name: str,
3
+ color: str;
4
+ }
5
+
6
+ glob a: list[fruit] = [
7
+ fruit(name="apple", color="red"),
8
+ fruit(name="banana", color="yellow"),
9
+ fruit(name="grape", color="purple")
10
+ ];
11
+
12
+ glob b: dict[str, fruit] = {
13
+ "a": fruit(name="apple", color="red"),
14
+ "b": fruit(name="banana", color="yellow"),
15
+ "c": fruit(name="grape", color="purple")
16
+ };
17
+
18
+ can foo(a: list[fruit]) -> list[fruit] {
19
+ return a[0:2];
20
+ }
21
+
22
+ with entry {
23
+ fruit_1 = a[0];
24
+ clr_1 = a[0].color;
25
+ clr_1 = b["a"].color;
26
+ f_clr = foo(a);
27
+ f_clrw = foo(a)[0];
28
+ f_clrw2 = foo(a)[0:1][0].color;
29
+ # print(foo(a)[0].color);
30
+ }
@@ -0,0 +1,14 @@
1
+ import from math { sin as s, cos, sqrt as sq }
2
+ include random;
3
+ import from ..test_cli, JacCliTests as Jac;
4
+ import from deep.mycode, code as c;
5
+ import hashcheck as h, assign_compr as a;
6
+ import from jacsamp, my_print as m;
7
+
8
+ with entry {
9
+ print(sq(4), s(30), cos(30));
10
+ print(randint(1, 10));
11
+ print(m("--->my_print<---"));
12
+ print(h.a, a.mvar);
13
+ print(c());
14
+ }
@@ -1,17 +1,17 @@
1
1
  glob x = 5, y = 2;
2
2
 
3
3
  test a {
4
- check assertAlmostEqual(5, x);
4
+ check almostEqual(5, x);
5
5
  }
6
6
 
7
7
  test b {
8
- check assertIn("l", "llm");
8
+ check "l" in "llm";
9
9
  }
10
10
 
11
11
  test c {
12
- check assertEqual(x - y, 3);
12
+ check x - y == 3;
13
13
  }
14
14
 
15
15
  test d {
16
- check assertEqual(1, 2);
16
+ check 1 == 2;
17
17
  }
@@ -3,7 +3,7 @@
3
3
  import:py os;
4
4
  import:py pyfunc;
5
5
  import:py random;
6
- import:py from pyfunc, my_print;
6
+ import:py from pyfunc { my_print }
7
7
 
8
8
  with entry {
9
9
  my_print(pyfunc);
@@ -11,7 +11,7 @@ with entry {
11
11
  }
12
12
 
13
13
  import:py circle_pysolo;
14
- import:py from circle_pysolo, calculate_area;
14
+ import:py from circle_pysolo { calculate_area }
15
15
 
16
16
  with entry {
17
17
  print(f"are {calculate_area(2.0)}");
@@ -79,7 +79,7 @@ for i in range(a):
79
79
  break
80
80
  print(b)
81
81
  else:
82
- print("Loop completed normally{}".format(i))
82
+ print(f"Loop completed normally{i}")
83
83
 
84
84
 
85
85
  def fooo45() -> None:
@@ -1,9 +1,9 @@
1
+ from __future__ import annotations
2
+
1
3
  # flake8: noqa
2
4
 
3
5
  """Python function for testing py imports."""
4
6
 
5
- from __future__ import annotations
6
-
7
7
 
8
8
  def count_up_to(n: int):
9
9
  """Count up to n"""
@@ -277,3 +277,6 @@ def foo() -> None:
277
277
 
278
278
 
279
279
  foo()
280
+
281
+ node = 90
282
+ print(node)
@@ -0,0 +1,3 @@
1
+ from .display import *
2
+ from .color import *
3
+ from .constants import *
@@ -0,0 +1,3 @@
1
+ class Color:
2
+ def __init__(self, value: int | str) -> None:
3
+ pass
@@ -0,0 +1,5 @@
1
+ CONST_VALUE: int = 0
2
+
3
+
4
+ class CL:
5
+ CONST_VALUE2: str = "h"
@@ -0,0 +1,2 @@
1
+ def set_mode(a, b):
2
+ pass
File without changes
@@ -0,0 +1,2 @@
1
+ def hello_world():
2
+ print("Hello")
@@ -24,6 +24,15 @@ glob personality_examples: 'Personality Information of Famous People': dict[str,
24
24
 
25
25
  glob person_value : list[tuple[dict[str, Personality], int]] =(-90);
26
26
 
27
+ can 'GenAI ability'
28
+ genai_ability(x: 'Something': str) -> 'Something Else': str by llm();
29
+
30
+ can 'Normal ability'
31
+ normal_ability(x: 'Something': str) -> 'Something Else': str {
32
+ y = 10;
33
+ return x;
34
+ }
35
+
27
36
  can foo() {
28
37
  person_value=22;
29
38
  can bar() {
@@ -1,17 +1,17 @@
1
1
  glob a = 5, b = 2;
2
2
 
3
3
  test t1 {
4
- check assertAlmostEqual(a, 6);
4
+ check almostEqual(a, 6);
5
5
  }
6
6
 
7
7
  test t2 {
8
- check assertTrue(a != b);
8
+ check a != b;
9
9
  }
10
10
 
11
11
  test t3 {
12
- check assertIn("d", "abc");
12
+ check "d" in "abc";
13
13
  }
14
14
 
15
15
  test t4 {
16
- check assertEqual(a - b, 3);
16
+ check a - b == 3;
17
17
  }
@@ -27,7 +27,4 @@ journal {
27
27
  can add() -> 'no of': int {}
28
28
 
29
29
  can 'update user mood'
30
- updateMood(* mood: 'Moo of the Person': str, something:'Something':str, something_else: 'Something Else': int = 5, without_semstr: float) -> 'mood selection': str {}
31
-
32
-
33
- can get_personality (person: 'Person Object': list[Person]) -> 'Personality of the Person': dict[Personality, PersonalityIndex] by llm(reason=True, incl_info=(personality_examples, self.diary_entries));
30
+ updateMood(* mood: 'Moo of the Person': str, something:'Something':str, something_else: 'Something Else': int = 5, without_semstr: float) -> 'mood selection': str {}
@@ -15,7 +15,7 @@ class SimpleClass {
15
15
  var2: int,
16
16
  var3: int = 0;
17
17
 
18
- can init {
18
+ can init(self: SimpleClass) {
19
19
  print(self.var3);
20
20
  }
21
21
  }
jaclang/tests/test_cli.py CHANGED
@@ -5,6 +5,7 @@ import io
5
5
  import os
6
6
  import subprocess
7
7
  import sys
8
+ import traceback
8
9
 
9
10
  from jaclang.cli import cli
10
11
  from jaclang.plugin.builtin import dotgen
@@ -38,7 +39,7 @@ class JacCliTests(TestCase):
38
39
  sys.stderr = captured_output
39
40
 
40
41
  try:
41
- cli.enter(self.fixture_abs_path("err2.jac"), entrypoint="speak", args=[]) # type: ignore
42
+ cli.enter(self.fixture_abs_path("err2.jac"), entrypoint="speak", args=[])
42
43
  except Exception as e:
43
44
  print(f"Error: {e}")
44
45
 
@@ -46,7 +47,66 @@ class JacCliTests(TestCase):
46
47
  sys.stderr = sys.__stderr__
47
48
  stdout_value = captured_output.getvalue()
48
49
  # print(stdout_value)
49
- self.assertIn("Syntax Error", stdout_value)
50
+ self.assertIn("Error", stdout_value)
51
+
52
+ def test_jac_cli_alert_based_runtime_err(self) -> None:
53
+ """Basic test for pass."""
54
+ captured_output = io.StringIO()
55
+ sys.stdout = captured_output
56
+ sys.stderr = captured_output
57
+
58
+ try:
59
+ cli.run(self.fixture_abs_path("err_runtime.jac"))
60
+ except Exception as e:
61
+ print(f"Error: {e}")
62
+
63
+ sys.stdout = sys.__stdout__
64
+ sys.stderr = sys.__stderr__
65
+
66
+ expected_stdout_values = (
67
+ "Error: list index out of range",
68
+ " print(some_list[invalid_index]);",
69
+ " ^^^^^^^^^^^^^^^^^^^^^^^^",
70
+ " at bar() ",
71
+ " at foo() ",
72
+ " at <module> ",
73
+ )
74
+
75
+ logger_capture = "\n".join([rec.message for rec in self.caplog.records])
76
+ for exp in expected_stdout_values:
77
+ self.assertIn(exp, logger_capture)
78
+
79
+ def test_jac_impl_err(self) -> None:
80
+ """Basic test for pass."""
81
+ if "jaclang.tests.fixtures.err" in sys.modules:
82
+ del sys.modules["jaclang.tests.fixtures.err"]
83
+ captured_output = io.StringIO()
84
+ sys.stdout = captured_output
85
+ sys.stderr = captured_output
86
+
87
+ try:
88
+ cli.enter(self.fixture_abs_path("err.jac"), entrypoint="speak", args=[])
89
+ except Exception:
90
+ traceback.print_exc()
91
+
92
+ sys.stdout = sys.__stdout__
93
+ sys.stderr = sys.__stderr__
94
+ stdout_value = captured_output.getvalue()
95
+ # print(stdout_value)
96
+ path_to_file = self.fixture_abs_path("err.impl.jac")
97
+ self.assertIn(f'"{path_to_file}", line 2', stdout_value)
98
+
99
+ def test_jac_test_err(self) -> None:
100
+ """Basic test for pass."""
101
+ captured_output = io.StringIO()
102
+ sys.stdout = captured_output
103
+ sys.stderr = captured_output
104
+ cli.test(self.fixture_abs_path("baddy.jac"))
105
+ sys.stdout = sys.__stdout__
106
+ sys.stderr = sys.__stderr__
107
+ stdout_value = captured_output.getvalue()
108
+ path_to_file = self.fixture_abs_path("baddy.test.jac")
109
+ self.assertIn(f'"{path_to_file}", line 2,', stdout_value)
50
110
 
51
111
  def test_jac_ast_tool_pass_template(self) -> None:
52
112
  """Basic test for pass."""
@@ -84,6 +144,52 @@ class JacCliTests(TestCase):
84
144
  stdout_value = captured_output.getvalue()
85
145
  self.assertIn("+-- Token", stdout_value)
86
146
 
147
+ def test_import_mod_abs_path(self) -> None:
148
+ """Testing for print AstTool."""
149
+ captured_output = io.StringIO()
150
+ sys.stdout = captured_output
151
+
152
+ cli.tool("ir", ["ast", f"{self.fixture_abs_path('import.jac')}"])
153
+
154
+ sys.stdout = sys.__stdout__
155
+ stdout_value = captured_output.getvalue()
156
+ self.assertRegex(
157
+ stdout_value,
158
+ r"1\:11 \- 1\:13.*ModulePath - os - abs_path\:.*typeshed/stdlib/os/__init__.pyi",
159
+ )
160
+ self.assertRegex(
161
+ stdout_value,
162
+ r"2\:11 \- 2\:14.*ModulePath - sys - abs_path\:.*typeshed/stdlib/sys/__init__.pyi",
163
+ )
164
+ self.assertRegex(
165
+ stdout_value,
166
+ r"3\:11 \- 3\:17.*ModulePath - pyfunc - abs_path\:.*fixtures/pyfunc.py",
167
+ )
168
+ self.assertRegex(
169
+ stdout_value,
170
+ r"4\:11 \- 4\:28.*ModulePath - pygame_mock - abs_path\:.*fixtures/pygame_mock/inner/__init__.py",
171
+ )
172
+ self.assertRegex(
173
+ stdout_value,
174
+ r"6\:11 \- 6\:15.*ModulePath - math - abs_path\:.*typeshed/stdlib/math.pyi",
175
+ )
176
+ self.assertRegex(
177
+ stdout_value,
178
+ r"7\:11 \- 7\:19.*ModulePath - argparse - abs_path\:.*typeshed/stdlib/argparse.pyi",
179
+ )
180
+ self.assertRegex(
181
+ stdout_value,
182
+ r"8\:16 \- 8\:27.*ModulePath - pygame_mock - abs_path\:.*fixtures/pygame_mock/__init__.py",
183
+ )
184
+ self.assertRegex(
185
+ stdout_value,
186
+ r"8\:30 \- 8:35.*ModuleItem - color - abs_path\:.*fixtures/pygame_mock/color.py",
187
+ )
188
+ self.assertRegex(
189
+ stdout_value,
190
+ r"8\:37 \- 8:44.*ModuleItem - display - abs_path\:.*fixtures/pygame_mock/display.py",
191
+ )
192
+
87
193
  def test_ast_dotgen(self) -> None:
88
194
  """Testing for print AstTool."""
89
195
  captured_output = io.StringIO()
@@ -102,7 +208,7 @@ class JacCliTests(TestCase):
102
208
  cli.check(f"{self.fixture_abs_path('game1.jac')}")
103
209
  sys.stdout = sys.__stdout__
104
210
  stdout_value = captured_output.getvalue()
105
- self.assertIn("Errors: 0, Warnings: 1", stdout_value)
211
+ self.assertIn("Errors: 0, Warnings: 2", stdout_value)
106
212
 
107
213
  def test_type_info(self) -> None:
108
214
  """Testing for type info inside the ast tool."""