summaryrefslogtreecommitdiffstats
path: root/tests/expected/sfdisk
diff options
context:
space:
mode:
authorKarel Zak2015-04-22 17:15:39 +0200
committerKarel Zak2015-04-22 17:31:40 +0200
commit9b4ffb45656c1430f94aaeb5886a767dd264173c (patch)
tree3f08ff50dab0af09a89adbdcd2c7ad8f6684de6d /tests/expected/sfdisk
parentlibfdisk: fix scriptk parser to support alone signs (diff)
downloadkernel-qcow2-util-linux-9b4ffb45656c1430f94aaeb5886a767dd264173c.tar.gz
kernel-qcow2-util-linux-9b4ffb45656c1430f94aaeb5886a767dd264173c.tar.xz
kernel-qcow2-util-linux-9b4ffb45656c1430f94aaeb5886a767dd264173c.zip
tests: add sfdisk resize regression tests for MBR
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'tests/expected/sfdisk')
-rw-r--r--tests/expected/sfdisk/resize0
-rw-r--r--tests/expected/sfdisk/resize-dos-0-move-up-absolute25
-rw-r--r--tests/expected/sfdisk/resize-dos-1-move-down-absolute25
-rw-r--r--tests/expected/sfdisk/resize-dos-10-down-enlarge25
-rw-r--r--tests/expected/sfdisk/resize-dos-11-absolute-move-resize25
-rw-r--r--tests/expected/sfdisk/resize-dos-12-reduce-midle29
-rw-r--r--tests/expected/sfdisk/resize-dos-13-max-last29
-rw-r--r--tests/expected/sfdisk/resize-dos-2-move-up-relative25
-rw-r--r--tests/expected/sfdisk/resize-dos-3-move-down-relative25
-rw-r--r--tests/expected/sfdisk/resize-dos-4-enlarge-absolute25
-rw-r--r--tests/expected/sfdisk/resize-dos-5-reduce-absolute25
-rw-r--r--tests/expected/sfdisk/resize-dos-6-enlarge-relative25
-rw-r--r--tests/expected/sfdisk/resize-dos-7-reduce-relative25
-rw-r--r--tests/expected/sfdisk/resize-dos-8-enlarge-all25
-rw-r--r--tests/expected/sfdisk/resize-dos-9-up-preduce25
15 files changed, 358 insertions, 0 deletions
diff --git a/tests/expected/sfdisk/resize b/tests/expected/sfdisk/resize
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/tests/expected/sfdisk/resize
diff --git a/tests/expected/sfdisk/resize-dos-0-move-up-absolute b/tests/expected/sfdisk/resize-dos-0-move-up-absolute
new file mode 100644
index 000000000..14d1a7656
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-0-move-up-absolute
@@ -0,0 +1,25 @@
+3000,
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 22527 20480 10M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 3000 23479 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-1-move-down-absolute b/tests/expected/sfdisk/resize-dos-1-move-down-absolute
new file mode 100644
index 000000000..feaa2b2e6
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-1-move-down-absolute
@@ -0,0 +1,25 @@
+2048,
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 3000 23479 20480 10M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 22527 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-10-down-enlarge b/tests/expected/sfdisk/resize-dos-10-down-enlarge
new file mode 100644
index 000000000..83eb2d8e8
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-10-down-enlarge
@@ -0,0 +1,25 @@
+-10M,+10M,,*
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 22528 204799 182272 89M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 204799 202752 99M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-11-absolute-move-resize b/tests/expected/sfdisk/resize-dos-11-absolute-move-resize
new file mode 100644
index 000000000..eef18a0d2
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-11-absolute-move-resize
@@ -0,0 +1,25 @@
+2048,10M,L
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 204799 202752 99M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 22527 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-12-reduce-midle b/tests/expected/sfdisk/resize-dos-12-reduce-midle
new file mode 100644
index 000000000..eaea4eb9a
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-12-reduce-midle
@@ -0,0 +1,29 @@
+,-5M
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 22527 20480 10M 83 Linux
+<removed>2 22528 43007 20480 10M 83 Linux
+<removed>3 43008 63487 20480 10M 83 Linux
+
+<removed>2:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 22527 20480 10M 83 Linux
+<removed>2 22528 32767 10240 5M 83 Linux
+<removed>3 43008 63487 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-13-max-last b/tests/expected/sfdisk/resize-dos-13-max-last
new file mode 100644
index 000000000..af514ac4e
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-13-max-last
@@ -0,0 +1,29 @@
+-5M,+
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 22527 20480 10M 83 Linux
+<removed>2 22528 32767 10240 5M 83 Linux
+<removed>3 43008 63487 20480 10M 83 Linux
+
+<removed>3:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 * 2048 22527 20480 10M 83 Linux
+<removed>2 22528 32767 10240 5M 83 Linux
+<removed>3 32768 204799 172032 84M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-2-move-up-relative b/tests/expected/sfdisk/resize-dos-2-move-up-relative
new file mode 100644
index 000000000..50cc67de7
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-2-move-up-relative
@@ -0,0 +1,25 @@
++1M,
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 22527 20480 10M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 4096 24575 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-3-move-down-relative b/tests/expected/sfdisk/resize-dos-3-move-down-relative
new file mode 100644
index 000000000..ec51a1257
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-3-move-down-relative
@@ -0,0 +1,25 @@
+-1M,
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 4096 24575 20480 10M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 22527 20480 10M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-4-enlarge-absolute b/tests/expected/sfdisk/resize-dos-4-enlarge-absolute
new file mode 100644
index 000000000..c3ce8b776
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-4-enlarge-absolute
@@ -0,0 +1,25 @@
+-,15M
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 22527 20480 10M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 32767 30720 15M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-5-reduce-absolute b/tests/expected/sfdisk/resize-dos-5-reduce-absolute
new file mode 100644
index 000000000..0ee2b075c
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-5-reduce-absolute
@@ -0,0 +1,25 @@
+,5M,
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 32767 30720 15M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 12287 10240 5M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-6-enlarge-relative b/tests/expected/sfdisk/resize-dos-6-enlarge-relative
new file mode 100644
index 000000000..312945dec
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-6-enlarge-relative
@@ -0,0 +1,25 @@
+, +10M
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 12287 10240 5M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 32767 30720 15M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-7-reduce-relative b/tests/expected/sfdisk/resize-dos-7-reduce-relative
new file mode 100644
index 000000000..f01e2a920
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-7-reduce-relative
@@ -0,0 +1,25 @@
+, -10M
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 32767 30720 15M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 12287 10240 5M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-8-enlarge-all b/tests/expected/sfdisk/resize-dos-8-enlarge-all
new file mode 100644
index 000000000..829dfd497
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-8-enlarge-all
@@ -0,0 +1,25 @@
+,+
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 12287 10240 5M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 204799 202752 99M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.
diff --git a/tests/expected/sfdisk/resize-dos-9-up-preduce b/tests/expected/sfdisk/resize-dos-9-up-preduce
new file mode 100644
index 000000000..a1119f147
--- /dev/null
+++ b/tests/expected/sfdisk/resize-dos-9-up-preduce
@@ -0,0 +1,25 @@
++10M,-10M
+
+Checking that no-one is using this disk right now ... OK
+
+Disk <removed>: 100 MiB, 104857600 bytes, 204800 sectors
+Units: sectors of 1 * 512 = 512 bytes
+Sector size (logical/physical): 512 bytes / 512 bytes
+I/O size (minimum/optimal): 512 bytes / 32768 bytes
+Disklabel type: dos
+Disk identifier: <removed>
+
+Old situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 2048 204799 202752 99M 83 Linux
+
+<removed>1:
+New situation:
+
+Device Boot Start End Sectors Size Id Type
+<removed>1 22528 204799 182272 89M 83 Linux
+
+The partition table has been altered.
+Calling ioctl() to re-read partition table.
+Syncing disks.