|
|
8d419f |
From e235b10483fb5b33f20ff0611ac5ed707d35d850 Mon Sep 17 00:00:00 2001
|
|
|
8d419f |
From: Frantisek Sumsal <frantisek@sumsal.cz>
|
|
|
8d419f |
Date: Fri, 18 Feb 2022 14:10:15 +0100
|
|
|
8d419f |
Subject: [PATCH] test: pass the initdir to check_result_{qemu,nspawn} hooks
|
|
|
8d419f |
|
|
|
8d419f |
(cherry picked from commit 4b9a0c3aebdcf000f8d7ee569cb8a1806d07c397)
|
|
|
8d419f |
|
|
|
8d419f |
Related: #2087652
|
|
|
8d419f |
---
|
|
|
8d419f |
test/test-functions | 8 ++++----
|
|
|
8d419f |
1 file changed, 4 insertions(+), 4 deletions(-)
|
|
|
8d419f |
|
|
|
8d419f |
diff --git a/test/test-functions b/test/test-functions
|
|
|
8d419f |
index b5fcf07818..93ab32b68d 100644
|
|
|
8d419f |
--- a/test/test-functions
|
|
|
8d419f |
+++ b/test/test-functions
|
|
|
8d419f |
@@ -1438,7 +1438,7 @@ check_result_nspawn() {
|
|
|
8d419f |
|
|
|
8d419f |
# Run additional test-specific checks if defined by check_result_nspawn_hook()
|
|
|
8d419f |
if declare -F check_result_nspawn_hook >/dev/null; then
|
|
|
8d419f |
- if ! check_result_nspawn_hook; then
|
|
|
8d419f |
+ if ! check_result_nspawn_hook "${workspace}"; then
|
|
|
8d419f |
derror "check_result_nspawn_hook() returned with EC > 0"
|
|
|
8d419f |
ret=4
|
|
|
8d419f |
fi
|
|
|
8d419f |
@@ -1457,16 +1457,16 @@ check_result_qemu() {
|
|
|
8d419f |
check_result_common "${initdir:?}"
|
|
|
8d419f |
ret=$?
|
|
|
8d419f |
|
|
|
8d419f |
- _umount_dir "${initdir:?}"
|
|
|
8d419f |
-
|
|
|
8d419f |
# Run additional test-specific checks if defined by check_result_qemu_hook()
|
|
|
8d419f |
if declare -F check_result_qemu_hook >/dev/null; then
|
|
|
8d419f |
- if ! check_result_qemu_hook; then
|
|
|
8d419f |
+ if ! check_result_qemu_hook "${initdir:?}"; then
|
|
|
8d419f |
derror "check_result_qemu_hook() returned with EC > 0"
|
|
|
8d419f |
ret=4
|
|
|
8d419f |
fi
|
|
|
8d419f |
fi
|
|
|
8d419f |
|
|
|
8d419f |
+ _umount_dir "${initdir:?}"
|
|
|
8d419f |
+
|
|
|
8d419f |
return $ret
|
|
|
8d419f |
}
|
|
|
8d419f |
|