better detect test succeeded

This commit is contained in:
Daniel Barlow 2023-12-22 15:29:33 +00:00
parent 231c2cef03
commit 5f9ffa804f
2 changed files with 4 additions and 2 deletions

View file

@ -17,7 +17,9 @@ in {
../../modules/outputs/ext4fs.nix
../../modules/outputs/tftpboot.nix
];
config = {
hostname = "tftpboot-test";
# use extracted dts if it was null in the device
# definition, use actual dts if provided
hardware.dts.src = lib.mkOverride 500 dts;

View file

@ -20,11 +20,11 @@ expect {
}
expect {
"#" { send "test -f /proc/device-tree/reserved-memory/phram-rootfs*/name && tty \r" }
"#" { send "test -f /proc/device-tree/reserved-memory/phram-rootfs*/name && hostname \r" }
timeout { exit 1 }
}
expect {
"/dev/ttyS0" { exit 0 }
"tftpboot-test" { exit 0 }
timeout { exit 1 }
}