smoketest: say once a minute that a command in the VM is still running
run_in_vm prints how long it has run and the log's latest line, so an hour-long install.sh shows progress without tail -f. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -138,6 +138,14 @@ upstream_main() {
|
||||
[ -f "$SMOKETEST_RESULTS/02-second.log" ]
|
||||
}
|
||||
|
||||
@test "run_in_vm says once a tick that it's still running, with the log's latest line" {
|
||||
export SMOKETEST_TICK=1
|
||||
run run_in_vm slow 'echo working; sleep 2.5'
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" == *" still running slow (0 min): working"* ]]
|
||||
[[ "$output" == *"== slow exited 0 (log: "* ]]
|
||||
}
|
||||
|
||||
@test "run_in_vm writes its log while the script runs" {
|
||||
run_in_vm slow 'echo early; cat "$SMOKETEST_RESULTS/01-slow.log" > "$HOME/seen"'
|
||||
[ "$STATUS" -eq 0 ]
|
||||
|
||||
Reference in New Issue
Block a user