Improve test coverage for prepare plugins in image mode#4719
Conversation
There was a problem hiding this comment.
Code Review
This pull request significantly improves test coverage for prepare plugins in image mode by refactoring existing tests and adding new ones for bootc-based guests. It also implements missing methods in the Bootc package manager to support these tests. The changes are well-structured and the new test infrastructure is a valuable addition. I have one suggestion to simplify some of the new shell helper functions for better readability.
65f03c7 to
022036b
Compare
|
@gemini-code-assist please review |
There was a problem hiding this comment.
Code Review
This pull request introduces comprehensive support for 'image-mode' guests within the TMT framework. Key changes include updating .packit.yaml and plans/provision/virtual.fmf to define a new provision-virtual-image-mode job and FMF plan, along with adding specific image definitions and helper functions in tests/images.sh. The testing infrastructure has been significantly adapted across tests/prepare/install/test.sh, tests/prepare/recommend/test.sh, and tests/prepare/shell/test.sh to accommodate image-mode specific behaviors like Containerfile builds, image switches, and reboot persistence. Core package management logic for image-mode guests, including COPR repository handling and package installation, has been implemented in tmt/package_managers/bootc.py. Several old test files related to bootc and CentOS Stream 10 have been removed.
0a72ea2 to
221d6c3
Compare
|
Fixed the
Assisted-by: Claude Code |
This comment was marked as resolved.
This comment was marked as resolved.
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
This reverts commit 05d59b0.
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Co-authored-by: Cristian Le <git@lecris.dev>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Script from remote url is broken, see #4785 Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
The `image` and `in_subdirectory` variables in `fetch_downloaded_packages()` were not declared `local`, so when `IMAGE_MODE=yes` the function overwrote the global loop `$image` (e.g. from the full qcow2 URL to `fedora:44`). Subsequent phases like "Install existing and invalid packages" then saw the wrong value, causing `is_image_mode` to return false and the test to check the wrong error message assertion. Assisted-by: Claude Code Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
Signed-off-by: Miroslav Vadkerti <mvadkert@redhat.com>
|
Linkcheck failed because of target site being down, merging. |
Incorporate the image mode testing into the plugins' tests and remove the separate
bootcspecific testing.Running the plugins test exercises all the cases as in package mode and provides good confidence about the
image mode testing support.
The testing is done against F44 and CS10 image mode cloud base images provided by Testing Farm.
Run the testing in a separate
/provision/virtual-image-modeplan, because the testing will similartime to run as
/provision/virtual.Fixes #4606
Pull Request Checklist
Assisted-by: Claude Code