Skip to content

test(images): add image-read-only-checks LISA qemu test suite#18042

Draft
liunan-ms wants to merge 1 commit into
microsoft:4.0from
liunan-ms:liunan/lisa_local_tests
Draft

test(images): add image-read-only-checks LISA qemu test suite#18042
liunan-ms wants to merge 1 commit into
microsoft:4.0from
liunan-ms:liunan/lisa_local_tests

Conversation

@liunan-ms

Copy link
Copy Markdown
Contributor

Summary

Adds the image-read-only-checks LISA qemu test suite for vm-base image validation and documents the pip-extras handling for libvirt.

Details

  • Defines the image-read-only-checks test suite (type lisa) that boots a QEMU VM from the built image artifact and runs a set of read-only (no reboot, no fresh VM) checks.
  • Documents why the upstream LISA libvirt pip extra is intentionally omitted from pip-extras: that extra pins libvirt-python ~= 9.3.0, which fails to build against a modern host libvirt (e.g. 11.x) because its bundled generator.py cannot map newer API entries in libvirt-api.xml. A host-matching libvirt-python (plus pycdlib) should be installed into the LISA venv out-of-band instead.

Testing

  • azldev image test vm-base --test-suite image-read-only-checks --image-path <qcow2> -> all 16 test cases PASSED on a local QEMU/libvirt host (libvirt 11.6.0).

Copilot AI review requested due to automatic review settings July 17, 2026 00:12

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a LISA-based QEMU validation suite for VM base images.

Changes:

  • Registers the suite for vm-base and vm-base-dev.
  • Configures 16 read-only checks against pinned LISA sources.
  • Documents libvirt dependency handling.

Comment thread base/images/images.toml
type = "lisa"
description = "Lisa read-only checks(no reboot, no fresh VM) on QEMU VM"

[test-suites.image-read-only-checks.lisa]
Comment thread base/images/images.toml
Comment on lines +193 to +195
# aborts the wheel build. libvirt-python must instead match the host libvirt
# version, so install it (plus pycdlib) into the LISA venv out-of-band, e.g.:
# <venv>/bin/pip install "libvirt-python==<host-libvirt-version>" "pycdlib~=1.12"
Comment thread base/images/images.toml
Comment on lines +205 to +207
# 'libvirt' is intentionally omitted here — its pin (~= 9.3.0) breaks against a
# modern host libvirt. Install a host-matching libvirt-python + pycdlib into the
# venv manually instead. See the note above this suite for details.

@tobiasb-ms tobiasb-ms left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue(blocking): The commit and PR name don't follow conventional commits. images is not one of the approved things. I suggest test(images): ....

Comment thread base/images/images.toml
description = "Lisa read-only checks(no reboot, no fresh VM) on QEMU VM"

[test-suites.image-read-only-checks.lisa]
# 'libvirt' is intentionally omitted here — its pin (~= 9.3.0) breaks against a

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue(blocking): You document this thing about libvirt not being in pip-extras here and above. Pick one please.

@liunan-ms liunan-ms changed the title images: add image-read-only-checks LISA qemu test suite test(images): add image-read-only-checks LISA qemu test suite Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants