()
| 1074 | |
| 1075 | #[test] |
| 1076 | fn test_run_does_not_leave_error_handler_active() { |
| 1077 | let program = r#" |
| 1078 | ON ERROR GOTO @handler |
| 1079 | END |
| 1080 | |
| 1081 | @handler |
| 1082 | PRINT "captured: "; ERRMSG |
| 1083 | END 1 |
| 1084 | "#; |
| 1085 | Tester::default() |
| 1086 | .set_program(None, program) |
| 1087 | .continue_from_here() |
| 1088 | .run("RUN") |
| 1089 | .expect_clear() |
| 1090 | .expect_program(None as Option<String>, program) |
| 1091 | .check() |
| 1092 | .run(r#"LOAD "missing-file""#) |
| 1093 | .expect_clear() |
| 1094 | .expect_err("1:1: Entry not found") |
| 1095 | .expect_program(None as Option<String>, program) |
| 1096 | .check(); |
| 1097 | } |
| 1098 | |
| 1099 | #[test] |
| 1100 | fn test_run_preserves_errmsg_across_commands() { |
nothing calls this directly
no test coverage detected