test: cover method subtraction return diagnostics

This commit is contained in:
Hermes Agent
2026-09-11 17:45:42 +00:00
parent 2b661f65e7
commit d4c9c0a26b
5 changed files with 14 additions and 3 deletions
+3
View File
@@ -37,6 +37,9 @@ EXPECTED = {
"tests/typecheck_function_return_subtraction_bad.claro": [
"tests/typecheck_function_return_subtraction_bad.claro:3: Type mismatch for return from total: subtraction needs NUMBER values, but \"oops\" looks like TEXT.",
],
"tests/typecheck_method_return_subtraction_bad.claro": [
"tests/typecheck_method_return_subtraction_bad.claro:6: Type mismatch for return from Player.total: subtraction 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.",
],