check (Function)
Signature: check(label: string, expected: any, actual: any) -> Unit
Description: Asserts expected equals actual and includes label in a mismatch diagnostic. Execution continues after a mismatch.
Parameters
- label (
string): A short description of what is being checked - expected (
any): The value the actual must equal - actual (
any): The computed value
Returns: Unit
Example
test("doubling", fn() => check("double", 42, 21 * 2))
test ("doubling", \() => check ("double", 42, 21 * 2))