debian-forge-composer/test
Tom Gundersen fbf137a1b7 test/cases: move checksum out of the compose struct
The intention is that the compose struct fully specifies the test
case, and pipeline and image-info specifies the expected outputs.
Lastly, the boot struct specifies how to boot-test the image.

The checksum does not fit into this scheme, as it is computed from
the compose by querying rpmmd, and it is then passed as an input to
distro.Pipeline in order to compute the pipeline.

Introduce a new struct, rpmmd, which will eventually contain all
the data returned from rpmmd.Depsolve and later passed to
distro.Pipeline. For now it only contains the checksum.

This is not a functional change.

Signed-off-by: Tom Gundersen <teg@jklm.no>
2020-03-08 21:05:01 +01:00
..
cases test/cases: move checksum out of the compose struct 2020-03-08 21:05:01 +01:00
cloud-init test/run: pass cloud-init data to qemu 2019-12-10 02:47:35 +01:00
keyring Introduce local boot test case for QCOW2 2019-11-11 15:47:01 +01:00
f27-build-from-ubuntu1804.json pipeline: support osbuild runners 2019-11-27 02:47:36 +01:00
README.md Add instructions how to install build-deps in test/README 2020-03-04 19:56:25 +01:00
run test/run: print more helpful output 2019-12-14 17:23:31 +01:00

osbuild-composer testing information

Integration testing

This will consume the osbuild-composer API surface via the composer-cli command line interface. Implementation is under cmd/osbuild-tests/.

The easiest way to get started with integration testing from a git checkout is:

  • dnf -y install rpm-build
  • dnf -y builddep golang-github-osbuild-composer.spec
  • make rpm to build the software under test
  • dnf install output/x86_64/golang-github-osbuild-composer-*.rpm - this will install both osbuild-composer, its -debuginfo, -debugsource and -tests packages
  • systemctl start osbuild-composer
  • /usr/libexec/tests/osbuild-composer/osbuild-tests to execute the test suite. It is best that you use a fresh system for installing and running the tests!

NOTE:

The easiest way to start osbuild-composer is via systemd because it takes care of setting up the UNIX socket for the API server.

If you are working on a pull request that adds more integration tests (without modifying osbuild-composer itself) then you can execute the test suite from the local directory without installing it:

  • make build - will build everything under cmd/
  • ./osbuild-tests - will execute the freshly built integration test suite