test: cover compatibility method addition diagnostics

This commit is contained in:
Hermes Agent
2026-09-12 22:32:45 +00:00
parent bbf1ad0b19
commit 747e8156e0
7 changed files with 42 additions and 2 deletions
+3
View File
@@ -55,6 +55,9 @@ EXPECTED = {
"tests/typecheck_method_return_multiplication_bad.claro": [
"tests/typecheck_method_return_multiplication_bad.claro:6: Type mismatch for return from Player.total: multiplication needs NUMBER values, but \"oops\" looks like TEXT.",
],
"tests/typecheck_method_compat_return_addition_bad.claro": [
"tests/typecheck_method_compat_return_addition_bad.claro:4: Type mismatch for return from Player.total: addition needs NUMBER values, but \"oops\" looks like TEXT.",
],
"tests/typecheck_function_unknown_return_expression_bad.claro": [
"tests/typecheck_function_unknown_return_expression_bad.claro:2: Function square's return value could not be understood yet. Use a NUMBER expression after RETURN.",
],