test: cover method return division diagnostics

This commit is contained in:
Hermes Agent
2026-09-12 01:58:25 +00:00
parent 45a323e45b
commit 3443fb7589
5 changed files with 14 additions and 3 deletions
+3
View File
@@ -46,6 +46,9 @@ EXPECTED = {
"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_method_return_division_bad.claro": [
"tests/typecheck_method_return_division_bad.claro:6: Type mismatch for return from Player.total: division 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.",
],