-
Notifications
You must be signed in to change notification settings - Fork 8
tests: Update tests_default.yml to do bootc end-to-end validation #59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tests: Update tests_default.yml to do bootc end-to-end validation #59
Conversation
Reviewer's GuideThis PR augments the CI workflows and test suite to enable bootc end-to-end validation by upgrading the tox-lsr dependency, pinning Podman 5.x for compatibility, refining the integration test invocations, and conditionally extending tests_default.yml with QEMU deployment tasks. Sequence Diagram: Bootc End-to-End Validation ProcesssequenceDiagram
participant GHA as GitHub Actions CI
participant TOX as tox / tox-lsr
participant BIB as Bootc Image Builder (Buildah)
participant QEMU as QEMU Environment
GHA->>TOX: Invoke tests (with bootc params)
activate TOX
TOX->>BIB: Request Bootc Image Build
activate BIB
BIB-->>TOX: Bootc Image Ready
deactivate BIB
TOX->>QEMU: Deploy Image and Start VM
activate QEMU
TOX->>QEMU: Run Validation Tests
QEMU-->>TOX: Test Results
deactivate QEMU
TOX-->>GHA: Overall Validation Status
deactivate TOX
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #59 +/- ##
=======================================
Coverage ? 52.31%
=======================================
Files ? 1
Lines ? 346
Branches ? 0
=======================================
Hits ? 181
Misses ? 165
Partials ? 0 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This *is* the correct name for our test dependency. The most recent codespell version started to complain about it.
1b4d83c to
184df35
Compare
f4eb28e to
26dafe8
Compare
Ubuntu 24.04's podman 4.9.3 does not work with the bootc-image-builder container: Bind-mounting the container storage into it makes the container's podman 5 fail with a storage error. Thus install podman 5.4 from Ubuntu 25.04 to regain compatibility. This is rather hackish, but as that is a stable release, it should not break in the future (wrt. library dependencies and such).
These tests run the role during a bootc container image build, deploy the container into a QEMU VM, boot that, and validate the expected configuration there. They run in two different tox environments, and thus have to be run in two steps (preparation in buildah, validation in QEMU). The preparation is expected to output a qcow2 image in `tests/tmp/TESTNAME/qcow2/disk.qcow2`, i.e. the output structure of <https://github.com/osbuild/bootc-image-builder>. There are two possibilities: * Have separate bootc end-to-end tests. These are tagged with `tests::bootc-e2` and are skipped in the normal qemu-* scenarios. They run as part of the container-* ones. * Modify an existing test: These need to build a qcow2 image exactly *once* (via calling `bootc-buildah-qcow.sh`) and skip setup/cleanup and role invocations in validation mode, i.e. when `__bootc_validation` is true. In the container scenario, run the QEMU validation as a separate step in the workflow. See https://issues.redhat.com/browse/RHEL-88396
Update tests_default.yml to build a QEMU deployment during bootc container runs after running the setup role. Skip setup/cleanup/role invocation during the QEMU validation run.
26dafe8 to
5506bae
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @martinpitt - I've reviewed your changes and they look great!
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Review instructions: all looks good
- 🟢 Testing: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
|
F41 failure is known, see https://bodhi.fedoraproject.org/updates/FEDORA-2025-f68c3fced6 . Will be fixed in a day or two when the new bootc version lands in Fedora. |
This is an alternative implementation of #58 which modifies an existing test instead of adding a new one. It shows that both approaches work, so depending on the role we can chose to modify an existing test or add a new one.
Summary by Sourcery
Implement end-to-end bootc validation in QEMU integration tests and update CI dependencies accordingly
New Features:
CI:
Tests: