mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
tests: Add a test of /dev/disk/by-id paths (RHBZ#627675).
This commit is contained in:
@@ -42,6 +42,11 @@ cat <<'EOF' > test.fstab
|
||||
|
||||
# Non-existent mountpoint.
|
||||
/dev/VG/LV1 /nosuchfile ext2 default 0 0
|
||||
|
||||
# /dev/disk/by-id path (RHBZ#627675).
|
||||
/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001 /id ext2 default 0 0
|
||||
/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001-part1 /id1 ext2 default 0 0
|
||||
/dev/disk/by-id/ata-QEMU_HARDDISK_QM00001-part3 /id3 ext2 default 0 0
|
||||
EOF
|
||||
|
||||
$guestfish -a test1.qcow2 <<'EOF'
|
||||
@@ -57,6 +62,9 @@ EOF
|
||||
|
||||
if [ "$(cat test.output)" != "/: /dev/VG/Root
|
||||
/boot: /dev/sda1
|
||||
/id1: /dev/sda1
|
||||
/id3: /dev/disk/by-id/ata-QEMU_HARDDISK_QM00001-part3
|
||||
/id: /dev/disk/by-id/ata-QEMU_HARDDISK_QM00001
|
||||
/nosuchfile: /dev/VG/LV1
|
||||
/var: /dev/sdb3" ]; then
|
||||
echo "$0: error #1: unexpected output from inspect-get-mountpoints command"
|
||||
|
||||
Reference in New Issue
Block a user