summaryrefslogtreecommitdiffstats
path: root/tests/templates/names_template
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-12-12 17:22:06 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-12-12 17:22:06 +0000
commit702eb8bf57b076e15e074f6a0c6fd04fb62546d9 (patch)
treee356c38fbe7b86af13593f321fa0da09a991e76f /tests/templates/names_template
parentAdding upstream version 4.3+20241108. (diff)
downloadmdadm-702eb8bf57b076e15e074f6a0c6fd04fb62546d9.tar.xz
mdadm-702eb8bf57b076e15e074f6a0c6fd04fb62546d9.zip
Adding upstream version 4.3+20241202.upstream/4.3+20241202upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/templates/names_template')
-rw-r--r--tests/templates/names_template6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/templates/names_template b/tests/templates/names_template
index c94245e..8060794 100644
--- a/tests/templates/names_template
+++ b/tests/templates/names_template
@@ -4,8 +4,6 @@ function names_create() {
local NAME=$2
local NEG_TEST=$3
- is_raid_foreign $DEVNAME
-
if [[ -z "$NAME" ]]; then
mdadm -CR "$DEVNAME" -l0 -n 1 $dev0 --force
else
@@ -34,6 +32,10 @@ function names_verify() {
local WANTED_NAME="$3"
local EXPECTED=""
+ # We don't know what is saved in metadata, but we know what to expect. Therfore check if
+ # expecation would be foreign (no hostname information).
+ is_raid_foreign $WANTED_NAME
+
local RES="$(mdadm -D --export $DEVNODE_NAME | grep MD_DEVNAME)"
if [[ "$?" != "0" ]]; then
echo "Cannot get details for $DEVNODE_NAME - unexpected devnode."