bug-parted
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] tests: t1100: show that adding a partition on a busy device succ


From: Jim Meyering
Subject: [PATCH] tests: t1100: show that adding a partition on a busy device succeeds
Date: Fri, 27 May 2011 17:07:46 +0200

FYI,

>From 077ece22959f808df80d2ffa9f0bc5fdf4a0707a Mon Sep 17 00:00:00 2001
From: Jim Meyering <address@hidden>
Date: Fri, 27 May 2011 17:06:31 +0200
Subject: [PATCH] tests: t1100: show that adding a partition on a busy device
 succeeds

* tests/t1100-busy-label.sh: Demonstrate that adding a partition
succeeds, even when another on the same device is mounted (active).
---
 tests/t1100-busy-label.sh |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/tests/t1100-busy-label.sh b/tests/t1100-busy-label.sh
index 9d230a8..f388308 100755
--- a/tests/t1100-busy-label.sh
+++ b/tests/t1100-busy-label.sh
@@ -21,7 +21,7 @@ require_root_
 require_scsi_debug_module_
 ss=$sector_size_

-scsi_debug_setup_ sector_size=$ss dev_size_mb=40 > dev-name ||
+scsi_debug_setup_ sector_size=$ss dev_size_mb=90 > dev-name ||
   skip_ 'failed to create scsi_debug device'
 dev=$(cat dev-name)

@@ -52,6 +52,12 @@ parted -s "$dev" mklabel msdos > out 2>&1; test $? = 1 || 
fail=1
 echo "Error: Partition(s) on $dev are being used." > exp
 compare out exp || fail=1

+# Adding a partition must succeed, even though another
+# on this same device is mounted (active).
+parted -s "$dev" mkpart primary fat32 41 85 > out 2>&1 || fail=1
+compare out /dev/null || fail=1
+parted -s "$dev" u s print
+
 # ==================================================
 # Repeat the test in interactive mode.
 # create input file
--
1.7.5.2.660.g9f46c



reply via email to

[Prev in Thread] Current Thread [Next in Thread]