Skip to content

Commit 47ab479

Browse files
committed
xtask: Implement bcvk-based tmt test runner
For local tests, right now testcloud+tmt doesn't support UEFI, see teemtee/tmt#4203 This is a blocker for us doing more testing with UKIs. In this patch we switch to provisioning VMs with bcvk, which fixes this - but beyond that a really compelling thing about this is that bcvk is *also* designed to be ergonomic and efficient beyond just being a test runner, with things like virtiofs mounting of host container storage, etc. In other words, bcvk is the preferred way to run local virt with bootc, and this makes our TMT tests use it. Now a major downside of this though is we're effectively implementing a new "provisioner" for tmt (bypassing the existing `virtual`). In the more medium term I think we want to add `bcvk` as a provisioner option to tmt. Anyways for now, this works by discovers test plans via `tmt plan ls`, spawning a separate VM per test, and then using uses tmt's connect provisioner to run tests targeting these externally provisioned systems. Assisted-by: Claude Code (Sonnet 4.5) Signed-off-by: Colin Walters <[email protected]>
1 parent 53a06ca commit 47ab479

File tree

4 files changed

+494
-18
lines changed

4 files changed

+494
-18
lines changed

Justfile

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -63,18 +63,17 @@ build-disk *ARGS:
6363
# updates are supported) as if it were a production environment use
6464
# https://github.com/teemtee/tmt.
6565
#
66-
# This task runs *all* of the tmt-based tests targeting the disk image generated
67-
# in the previous step.
68-
test-tmt *ARGS: build-disk
69-
./tests/run-tmt.sh {{ARGS}}
66+
# This task runs *all* of the tmt-based tests using bcvk VMs
67+
test-tmt *ARGS: build-integration-test-image
68+
cargo xtask run-tmt localhost/bootc-integration {{ARGS}}
7069

71-
# Like test-tmt but assumes that a disk image is already built
70+
# Like test-tmt but assumes that the integration image is already built
7271
test-tmt-nobuild *ARGS:
73-
./tests/run-tmt.sh {{ARGS}}
72+
cargo xtask run-tmt localhost/bootc-integration {{ARGS}}
7473

75-
# Run just one tmt test: `just test-tmt-one test-20-local-upgrade`
76-
test-tmt-one PLAN: build-disk
77-
./tests/run-tmt.sh plan --name {{PLAN}}
74+
# Run just one tmt test: `just test-tmt-one readonly-tests`
75+
test-tmt-one PLAN: build-integration-test-image
76+
cargo xtask run-tmt localhost/bootc-integration {{PLAN}}
7877

7978
# Run tests (unit and integration) that are containerized
8079
test-container: build-units build-integration-test-image

crates/xtask/src/man.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ pub fn sync_all_man_pages(sh: &Shell) -> Result<()> {
398398

399399
/// Generate man pages from hand-written markdown sources
400400
#[context("Generating manpages")]
401-
pub fn generate_man_pages(sh: &Shell) -> Result<()> {
401+
pub fn generate_man_pages(sh: &Shell, _args: &[String]) -> Result<()> {
402402
let man_src_dir = Utf8Path::new("docs/src/man");
403403
let man_output_dir = Utf8Path::new("target/man");
404404

0 commit comments

Comments
 (0)