foundry
Foundry OS: the operating system built on the Rustbelt kernel
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | # v2-test.sh: boot contract v2 checks, run by dash (milestone M3).
# The self-test runs it as `dash /scripts/v2-test.sh`. Each check prints
# "v2-test: ok NAME" or "v2-test: FAIL NAME"; the exit status is the
# number of failures. What "contract v2" promises is in docs/boot-contract.md.
fails=0 checks=0
# roundtrip FILE: write two lines, read them back, delete, check it's gone.
# The environment the kernel gives pid 1, passed on by init.
# The root file system (A:, ext2): layout and writable.
# /bin/sh is dash; the Rust tools come first on PATH, the kernel's ABI
# test programs (on B:) last.
# The data disk (B:, FAT32) at /mnt/disk0.
# The share (C:, exFAT) at /mnt/share: write, read back, delete; a
# directory too; and the README that `make image` put there.
&&
# A file left on the share for the host to read after the run
# (make test checks it with scripts/exfat.py and fsck.exfat).
# An orphan for init: the subshell exits at once, its `sleep` lives on and
# is adopted by init, which must reap it (the self-test's memory check
# waits for every process to be gone).
( &)
if [; then
else ; fi
|