From: Thomas Weißschuh Date: Mon, 10 Oct 2022 21:07:25 +0000 (+0200) Subject: libblkid: apfs: add test X-Git-Tag: v2.39-rc1~489^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8fcd9405a48f478d75337d9d04c3e2d0d86a9f87;p=thirdparty%2Futil-linux.git libblkid: apfs: add test Fixes #1807 Information known to macOS: ``` $ hdiutil attach apfs.img /dev/disk1 /dev/disk2 EF57347C-0000-11AA-AA11-0030654 /dev/disk2s1 41504653-0000-11AA-AA11-0030654 /Volumes/testapfs $ diskutil info disk2 Device Identifier: disk2 Device Node: /dev/disk2 Whole: Yes Part of Whole: disk2 Device / Media Name: Disk Image Volume Name: Not applicable (no file system) Mounted: Not applicable (no file system) File System: None Content (IOContent): EF57347C-0000-11AA-AA11-00306543ECAC OS Can Be Installed: No Media Type: Generic Protocol: Disk Image SMART Status: Not Supported Disk / Partition UUID: 25E5F1D3-11C0-4D36-98A5-3F66953519B9 Disk Size: 10.5 MB (10485760 Bytes) (exactly 20480 512-Byte-Units) Device Block Size: 4096 Bytes Read-Only Media: No Read-Only Volume: Not applicable (no file system) Device Location: External Removable Media: Removable Media Removal: Software-Activated Virtual: Yes $ diskutil info disk2s1 Device Identifier: disk2s1 Device Node: /dev/disk2s1 Whole: No Part of Whole: disk2 Volume Name: testapfs Mounted: Yes Mount Point: /Volumes/testapfs Partition Type: 41504653-0000-11AA-AA11-00306543ECAC File System Personality: APFS Type (Bundle): apfs Name (User Visible): APFS Owners: Disabled OS Can Be Installed: Yes Media Type: Generic Protocol: Disk Image SMART Status: Not Supported Volume UUID: 3EA5C1EF-64CB-447C-AE37-8046CDC35010 Disk / Partition UUID: 3EA5C1EF-64CB-447C-AE37-8046CDC35010 Disk Size: 10.5 MB (10485760 Bytes) (exactly 20480 512-Byte-Units) Device Block Size: 4096 Bytes Volume Total Space: 10.5 MB (10485760 Bytes) (exactly 20480 512-Byte-Units) Volume Used Space: 376.8 KB (376832 Bytes) (exactly 736 512-Byte-Units) (3.6%) Volume Free Space: 10.1 MB (10108928 Bytes) (exactly 19744 512-Byte-Units) (96.4%) Allocation Block Size: 4096 Bytes Read-Only Media: No Read-Only Volume: No Device Location: External Removable Media: Removable Media Removal: Software-Activated ``` --- diff --git a/tests/expected/blkid/low-probe-apfs b/tests/expected/blkid/low-probe-apfs new file mode 100644 index 0000000000..492edfdea5 --- /dev/null +++ b/tests/expected/blkid/low-probe-apfs @@ -0,0 +1,6 @@ +ID_FS_BLOCK_SIZE=4096 +ID_FS_FSBLOCKSIZE=4096 +ID_FS_TYPE=apfs +ID_FS_USAGE=filesystem +ID_FS_UUID=25e5f1d3-11c0-4d36-98a5-3f66953519b9 +ID_FS_UUID_ENC=25e5f1d3-11c0-4d36-98a5-3f66953519b9 diff --git a/tests/ts/blkid/images-fs/apfs.img.xz b/tests/ts/blkid/images-fs/apfs.img.xz new file mode 100644 index 0000000000..4145c011b0 Binary files /dev/null and b/tests/ts/blkid/images-fs/apfs.img.xz differ