()
| 317 | |
| 318 | #[test] |
| 319 | fn test_ubound_ok() { |
| 320 | Tester::default() |
| 321 | .run("DIM x(10): result = UBOUND(x)") |
| 322 | .expect_var("result", 9i32) |
| 323 | .expect_array("x", ExprType::Integer, &[10], vec![]) |
| 324 | .check(); |
| 325 | |
| 326 | Tester::default() |
| 327 | .run("DIM x(10, 20): result = UBOUND(x, 1)") |
| 328 | .expect_var("result", 9i32) |
| 329 | .expect_array("x", ExprType::Integer, &[10, 20], vec![]) |
| 330 | .check(); |
| 331 | |
| 332 | Tester::default() |
| 333 | .run("DIM x(10, 20): result = UBOUND(x, 2.1)") |
| 334 | .expect_var("result", 19i32) |
| 335 | .expect_array("x", ExprType::Integer, &[10, 20], vec![]) |
| 336 | .check(); |
| 337 | } |
| 338 | |
| 339 | #[test] |
| 340 | fn test_ubound_errors() { |
nothing calls this directly
no test coverage detected