canonical / checkbox

Checkbox is a testing framework used to validate device compatibility with Ubuntu Linux. It’s the testing tool developed for the purposes of the Ubuntu Certification program.
https://checkbox.readthedocs.io
GNU General Public License v3.0
33 stars 49 forks source link

Skip `disk/storage_device_.*` if disk is not partitioned #1512

Open pieqq opened 1 month ago

pieqq commented 1 month ago

Enhancement Proposal

This desktop PC device has been failing disk/storage_device_sda for quite a while now with output:

Testing disk sda identified as a disk...
ERROR: No suitable partitions found on device /dev/sda 

lsblk attachment job shows

KNAME="sda" TYPE="disk" MOUNTPOINT=""

which indicates that this drive is not mounted, and does not have any partition.

Because of the way provisioning is done in the lab, devices with multiples disks usually only partition one of the disks to install the system, and leave the other disks unpartitioned and unmounted.

This test case should be skipped if the disk is not partitioned.

More information: discussion on Mattermost.

syncronize-issues-to-jira[bot] commented 1 month ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/CHECKBOX-1594.

This message was autogenerated

rodwsmith commented 1 month ago

From a server certification perspective, I don't think that skipping the test if the disk is unpartitioned is the right approach. For server certification, disks are supposed to be partitioned, and a skipped test if a disk is unpartitioned would be bad; the test really should fail in that case, from our perspective. Would it be possible to add a parameter to the test so that it can be called differently for devices, if a skip behavior is preferable there, leaving the existing behavior for server?

bladernr commented 1 month ago

A fairly easy option, I think, would be to add something like a --skip-unpartitioned-disks arg to the disk test and then call that in an SRU test definition or wherever else is appropriate, leaving the default to fail on those disks for cert purposes.

with server cert we do require the OEMs to partition and test any storage device installed in an SUT.