MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / example_array_assembles_and_runs

Function example_array_assembles_and_runs

tests/integration/kernel_integration.rs:1462–1483  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1460 assert!(
1461 uart.contains("HELLO"),
1462 "`la` + .asciz did not print the data-section string; uart={uart:?}"
1463 );
1464 assert!(
1465 uart.contains("[exit 42]"),
1466 "call/ret did not produce exit 42; uart={uart:?}"
1467 );
1468 assert!(
1469 matches!(outcome, RunOutcome::Halted(0)),
1470 "shell did not survive the run and exit cleanly; outcome={outcome:?} uart={uart:?}"
1471 );
1472}
1473
1474#[test]
1475fn kernel_shell_assembles_section_and_data_directives() {
1476 let source = b"\
1477.section .text
1478.globl _start
1479_start:
1480 la t0, bytes
1481 lbu t1, 0(t0)
1482 li t2, 7
1483 bne t1, t2, fail
1484 lw t1, 4(t0)
1485 li t2, 42
1486 bne t1, t2, fail

Callers

nothing calls this directly

Calls 1

run_tool_sessionFunction · 0.85

Tested by

no test coverage detected