-
Notifications
You must be signed in to change notification settings - Fork 387
Open
Description
The integration test for kernel/block is flaky on my end. Since it was failing for me a few times I decided to test it:
#!/bin/sh
# repeat-test.sh
count=$1; shift
run() {
if "$@"; then ok=$((ok + 1))
else err=$((err + 1))
fi
}
echo "running test ${count} times: $*"
ok=0; err=0
while [ "$count" -gt 0 ]; do
count=$((count - 1))
run "$@" >/dev/null 2>/dev/null
done
printf "summary:\n ok=%d\n err=%d\n" "${ok}" "${err}"./repeat-test.sh 100 \
nix-build ./unikernel.nix \
--argstr unikernel ./test/integration/kernel/block \
--check \
--arg doCheck trueWhich reports 2 failures. I didn't dig too deep into the source of the fault, but the test does call Timers::oneshot() => Timers::periodic(). When it fails, it fails on the very first iteration of the test too from what I have observed (could be a coincidence).
@MagnusS Introducing a way to repeat tests to detect these sporadic failures is probably a good idea.
Metadata
Metadata
Assignees
Labels
No labels