Test assertions. import testing.
Assert that a function throws an error containing the expected message.
testing.assert_throws(fn() => panic("oh no"), "oh no")
Assert that a string contains a substring.
testing.assert_contains("hello world", "world")
Assert two floats are approximately equal within tolerance.
testing.assert_approx(3.14, 3.14159, 0.01)
Assert that a is greater than b.
testing.assert_gt(10, 5)
Assert that a is less than b.
testing.assert_lt(3, 7)
Assert that an Option is some (not none).
testing.assert_some(some("value"))
Assert that a Result is ok (not err).
testing.assert_ok(ok("success"))