test: cover compatibility method multiplication returns

This commit is contained in:
Hermes Agent
2026-09-12 18:25:09 +00:00
parent 55e783e2c3
commit f921e2d77d
8 changed files with 38 additions and 3 deletions
@@ -110,6 +110,12 @@ class ValidateTypecheckDiagnosticsTests(unittest.TestCase):
def test_includes_compatibility_method_return_success_fixture(self):
self.assertIn("tests/typecheck_method_compat_return_good.claro", MODULE.EXPECTED_OK)
def test_includes_compatibility_method_multiplication_return_success_fixture(self):
self.assertIn(
"tests/typecheck_method_compat_return_multiplication_good.claro",
MODULE.EXPECTED_OK,
)
def test_includes_lowercase_compatibility_method_return_success_fixture(self):
self.assertIn(
"tests/typecheck_method_compat_lowercase_return_good.claro",
@@ -0,0 +1,9 @@
CLASS Player
TEACH score TAKES amount RETURNS NUMBER
CHECK TYPE amount IS NUMBER
RETURN amount * 2
LEARNED
ENDCLASS
NEW Player player
CALL player.score WITH 4