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 50 forks source link

Refactor DSS provider tests (New) #1601

Closed motjuste closed 6 days ago

motjuste commented 1 week ago

Description

The tests for DSS provider in contrib have been refactored so that they use individual scripts now available in the relevant bin folder instead of scripts written inline in the jobs' command. The tests end up checking the same things, but are now better implemented.

The shell scripts were extracted out into one of multiple ones that roughly group related tests, including those generic to DSS, those for setting up Intel GPUs, those for using ITEX, and those for using IPEX. Furthermore, larger Python scripts that were previously written in-line have been factored out into individual ones. Please note that these Python scripts are not meant to be run by the jobs directly, instead they are submitted via the job to DSS to be run in the appropriate Kubernetes Pods, hence the Python dependencies of these scripts are not relevant to the provider itself.

Resolved issues

Documentation

No updates to Checkbox documentation.

Tests

Manual testing with the following Testflinger job spec had a successful run.

Testflinger job-spec ```yaml job_queue: dell-precision-3470-c30322 provision_data: distro: jammy test_data: test_cmds: | ssh -t ubuntu@$DEVICE_IP ' export DEBIAN_FRONTEND=noninteractive sudo apt update sudo apt -y install git git clone -b CHECKBOX-1587-refactor-dss-provider https://github.com/canonical/checkbox.git cd checkbox/contrib/checkbox-dss-validation sudo snap install --classic snapcraft sudo snap install checkbox22 lxd init --auto snapcraft sudo snap install --dangerous --classic ./checkbox-dss_*_amd64.snap checkbox-dss.install-deps checkbox-dss.validate-intel-gpu ' ```

Furthermore, the relevant GitHub workflow was also manually run with results available here