Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests/int/cpt: better debug #2877

Merged
merged 2 commits into from
Mar 29, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions tests/integration/checkpoint.bats
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ function runc_restore_with_pipes() {
echo "__runc restore $name failed (status: $ret)"
exec {err_w}>&-
cat <&${err_r}
echo "CRIU restore log errors (if any):"
grep -B 5 Error "$workdir"/restore.log || true
echo "CRIU log errors (if any):"
grep -B 5 Error "$workdir"/*.log ./image-dir/*.log || true
fail "runc restore failed"
fi

Expand Down Expand Up @@ -185,8 +185,8 @@ function simple_cr() {
exec {lazy_w}>&-
# shellcheck disable=SC2116,SC2086
out=$(echo $out) # rm newlines
# show log in case something is wrong before we fail
cat ./work-dir/dump.log
# show errors if there are any before we fail
grep -B5 Error ./work-dir/dump.log || true
# expecting \0 which od prints as
[ "$out" = "0000000 000000 0000001" ]

Expand Down