Решение на Basic BASIC от Тодор Кюркчиев
Обратно към всички решения
Към профила на Тодор Кюркчиев
Резултати
- 12 точки от тестове
- 0 бонус точки
- 12 точки общо
- 9 успешни тест(а)
- 6 неуспешни тест(а)
Код
Лог от изпълнението
Compiling solution v0.1.0 (/tmp/d20230111-3772066-1i0vg7b/solution)
Finished test [unoptimized + debuginfo] target(s) in 1.46s
Running tests/solution_test.rs (target/debug/deps/solution_test-0edbea2040daef01)
running 15 tests
test solution_test::test_basic_goto ... FAILED
test solution_test::test_basic_if ... FAILED
test solution_test::test_basic_print ... ok
test solution_test::test_basic_input ... ok
test solution_test::test_erroring_goto ... ok
test solution_test::test_basic_read ... ok
test solution_test::test_io_error_read ... ok
test solution_test::test_full_program ... FAILED
test solution_test::test_io_error_write ... ok
test solution_test::test_line_order_and_overwriting ... ok
test solution_test::test_print_cyrillic ... ok
test solution_test::test_runtime_errors ... FAILED
test solution_test::test_print_vars_and_strings ... ok
test solution_test::test_syntax_errors_1 ... FAILED
test solution_test::test_syntax_errors_2 ... FAILED
failures:
---- solution_test::test_basic_goto stdout ----
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
left: `"1\n2\n3\n"`,
right: `"1\n3\n"`', tests/solution_test.rs:193:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
thread 'solution_test::test_basic_goto' panicked at 'assertion failed: `(left == right)`
left: `"1\n2\n3\n"`,
right: `"1\n3\n"`', tests/solution_test.rs:180:5
---- solution_test::test_basic_if stdout ----
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
left: `"0\n1\n"`,
right: `"1\n"`', tests/solution_test.rs:224:9
thread 'solution_test::test_basic_if' panicked at 'assertion failed: `(left == right)`
left: `"0\n1\n"`,
right: `"1\n"`', tests/solution_test.rs:212:5
---- solution_test::test_full_program stdout ----
thread '<unnamed>' panicked at 'assertion failed: `(left == right)`
left: `"too_high\ntoo_low\nyou_got_it!\n"`,
right: `"too_low\ntoo_high\nyou_got_it!\n"`', tests/solution_test.rs:248:9
thread 'solution_test::test_full_program' panicked at 'assertion failed: `(left == right)`
left: `"too_high\ntoo_low\nyou_got_it!\n"`,
right: `"too_low\ntoo_high\nyou_got_it!\n"`', tests/solution_test.rs:230:5
---- solution_test::test_runtime_errors stdout ----
thread '<unnamed>' panicked at 'Expression Err(UnknownVariable { name: "A" }) does not match the pattern "Err(InterpreterError::RuntimeError { line_number: 11, .. })"', tests/solution_test.rs:307:9
thread 'solution_test::test_runtime_errors' panicked at 'Expression Err(UnknownVariable { name: "A" }) does not match the pattern "Err(InterpreterError::RuntimeError { line_number: 11, .. })"', tests/solution_test.rs:301:5
---- solution_test::test_syntax_errors_1 stdout ----
thread '<unnamed>' panicked at 'Expression Ok(()) does not match the pattern "Err(InterpreterError::SyntaxError { .. })"', tests/solution_test.rs:259:9
thread 'solution_test::test_syntax_errors_1' panicked at 'Expression Ok(()) does not match the pattern "Err(InterpreterError::SyntaxError { .. })"', tests/solution_test.rs:254:5
---- solution_test::test_syntax_errors_2 stdout ----
thread '<unnamed>' panicked at 'Expression Ok(()) does not match the pattern "Err(InterpreterError::SyntaxError { .. })"', tests/solution_test.rs:280:9
thread 'solution_test::test_syntax_errors_2' panicked at 'Expression Ok(()) does not match the pattern "Err(InterpreterError::SyntaxError { .. })"', tests/solution_test.rs:275:5
failures:
solution_test::test_basic_goto
solution_test::test_basic_if
solution_test::test_full_program
solution_test::test_runtime_errors
solution_test::test_syntax_errors_1
solution_test::test_syntax_errors_2
test result: FAILED. 9 passed; 6 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
error: test failed, to rerun pass `--test solution_test`
История (4 версии и 2 коментара)
Тодор качи първо решение на 10.01.2023 11:48 (преди над 2 години)
Тодор качи решение на 10.01.2023 13:03 (преди над 2 години)
Тодор качи решение на 10.01.2023 13:25 (преди над 2 години)
Тодор качи решение на 10.01.2023 14:12 (преди над 2 години)