1
0
mirror of https://github.com/systemd/systemd synced 2024-07-09 12:36:12 +00:00
Commit Graph

45 Commits

Author SHA1 Message Date
Daan De Meyer
fedac4c279 test: Extend meson + mkosi integration test docs
Let's also put the meson + mkosi docs first to nudge readers towards
it instead of the old fashioned way to run the integration tests.
2024-05-27 13:59:26 +02:00
Daan De Meyer
65638f4855 Rewrite testsuite README in markdown
Let's use markdown here like we do for everything else as well.
2024-05-27 13:59:05 +02:00
Luca Boccassi
e8b81df8b2 docs: add note about URL where to find recent Ubuntu CI logs 2024-05-27 09:50:50 +02:00
Luca Boccassi
c8de1a8c56 docs: move information from AUTOPKGTEST.md to test/README.testsuite and delete it
This is not information that needs to be published on systemd.io as it's
purely internal, so the README is enough
2024-05-01 01:30:12 +01:00
Daan De Meyer
cf5e1b5d39 test: Skip meson integration tests if SYSTEMD_INTEGRATION_TESTS != 1
We cannot mark a test suite as excluded by default in meson. Instead,
let's require that SYSTEMD_INTEGRATION_TESTS=1 and skip any integration
test if it's not set. This is effectively the same as excluding it by
default. If the integration-test option is enabled, we'll set the
environment variable by default, just like we do with SYSTEMD_SLOW_TESTS
and the slow-tests meson option.
2024-04-25 17:06:40 +02:00
Daan De Meyer
b85e54961c test: Various mkosi integration test improvements
- Stop using logging module since the default output formatting is
  pretty bad. Prefer print() for now.
- Log less, logging the full mkosi command line is rather verbose,
  especially when it contains multi-line dropins.
- Streamline the journalctl command we output for debugging failed
  tests.
- Don't force usage of the disk image format.
- Don't force running without unit tests.
- Don't force disabling RuntimeBuildSources.
- Update documentation to streamline the command for running a single
  test and remove sudo as it's not required anymore.
- Improve the console output by having the test unit's output logged
  to both the journal and the console.
- Disable journal console log forwarding as we have journal forwarding
  as a better alternative.
- Delete existing journal file before running test.
- Delete journal files of succeeded tests to reduce disk usage.
- Rename system_mkosi target to just mkosi
- Pass in mkosi source directory explicitly to accomodate arbitrary
  build directory locations.
- Add test interactive debugging if stdout is connected to a tty
- Stop explicitly using the 'system' image since it'll likely be
  dropped soon.
- Only forward journal if we're not running in debugging mode.
- Stop using testsuite.target and instead just add the necessary
  extras to the main testsuite unit via the credential dropin.
- Override type to idle so test output is not interleaved with
  status output.
- Don't build mkosi target by default
- Always add the mkosi target if mkosi is found
- Remove dependency of the integration tests on the mkosi target
  as otherwise the image is always built, even though we configure
  it to not be built by default.
- Move mkosi output, cache and build directory into build/ so that
  invocations from meson and regular invocations share the same
  directories.
- Various aesthetic cleanups.
2024-04-23 10:32:42 +02:00
Richard Maw
945b722f13 test: Add mkosi-based integration test runner
The first two tests are included to ensure parallel test execution is
demonstrable.
2024-04-18 16:26:38 +01:00
Frantisek Sumsal
844af666ed test: add instructions on how to run Coverity locally
This requires a Coverity license, so the usefulness of the instructions
is somewhat limited, but at least I won't have to re-discover everything
from scratch when I need to debug something Coverity-related again in the
future.
2024-04-12 14:42:00 +02:00
Luca Boccassi
22a36720bf test: explain how Ubuntu CI log URLs are created
Not trivially obvious, so add a couple of paragraph to explain it
2024-03-24 16:53:01 +01:00
Luca Boccassi
132f785429 test/README: document how to add a new empty release to the PPA to migrate the CI to a new version 2024-02-28 01:08:57 +00:00
Luca Boccassi
f6387e7e3f test/README: update ubuntu IRC channel for CI help 2024-02-28 01:08:57 +00:00
Frantisek Sumsal
59461f086f test: update Ubuntu CI instructions 2023-11-15 14:58:20 +01:00
Frantisek Sumsal
78ea6a549f test: update Ubuntu CI instructions 2023-10-14 17:40:07 +02:00
Jan Janssen
592ee08f3b ci: Use add-apt-repository to enable sources
This should also ensure that consistent mirrors are selected.
2023-09-06 11:01:53 +02:00
Frantisek Sumsal
0efa27bd4b test: allow running only specified subtests/testcases
Useful when debugging, e.g.:

make -C test/TEST-74-AUX-UTILS clean setup run TEST_MATCH_SUBTEST=run

Resolves: #27914
2023-06-05 15:58:37 +02:00
Zbigniew Jędrzejewski-Szmek
b13d59243b test/README: fix advice for testsuite debugging
KERNEL_APPEND="systemd.unit=multi-user.target" is not very useful, because the
machine will still shut down as soon as the tests succeeds or fails. But
INTERACTIVE_DEBUG=1 works great, so let's simplify the instructions and
recommend that.
2023-05-30 09:46:20 +02:00
Frantisek Sumsal
9fd8226312 test: shed some light into the whole coverage situation 2023-04-01 12:15:42 +02:00
Frantisek Sumsal
48e582d7fe test: update Ubuntu CI docs 2023-01-19 13:54:31 +01:00
Franck Bui
eb1f60230a test: fix the default timeout values described in README.testsuite
Unlike it was described, the default is 30 min.
2022-11-18 11:09:44 +01:00
Luca Boccassi
542e6eb38d
Merge pull request #24799 from poettering/initrd-ftw
use "initrd" rather than "initial RAM disk" or "initramfs" to refernce the concept
2022-09-23 20:43:15 +01:00
Lennart Poettering
32e2767080 tree-wide: use the term "initrd" at most places we so far used "initramfs"
In most cases we refernced the concept as "initrd". Let's convert most
remaining uses of "initramfs" to "initrd" too, to stay internally
consistent.

This leaves "initramfs" only where it's relevant to explain historical
concepts or where "initramfs" is part of the API (i.e. in
/run/initramfs).

Follow-up for: b66a6e1a58
2022-09-23 15:10:53 +02:00
Yu Watanabe
0b0cdb1652 doc: drop remaining references to LGTM.com 2022-09-23 18:29:22 +09:00
Zbigniew Jędrzejewski-Szmek
3e8caa34d6 docs: use lowercase "qemu" and other minor tweaks to test docs
We used both "qemu" and "QEMU", let's use the lower-case version everywhere
since it's also the name of the binary and the version that people are
most familiar with.

The stuff under test/ is not only for the integeration tests, but also
for various other test-related stuff, so adjust the docs a bit.
2022-05-04 12:58:43 +02:00
Frantisek Sumsal
42734a21eb test: document how to run CodeQL/LGTM stuff manually
Let's have this documented somewhere so I don't have to relearn all this
stuff every time I need it.
2022-03-11 16:51:53 +01:00
Frantisek Sumsal
4ba5594390 test: document how to manually run Ubuntu CI stuff
Every time I need it I have to first relearn autopkgtest and find where
all the necessary stuff lives, so let's document it somewhere close to
systemd for (at least) future me.
2022-02-10 13:53:10 +00:00
Luca Boccassi
e236711fd7 test: document autopkgtest CI infrastructure 2021-09-15 14:58:38 +02:00
Dan Streetman
232add5c47 test: allow run-integration-tests.sh to run without build 2021-01-26 17:09:48 -05:00
Dan Streetman
12d31e4ea5 test: find $BUILD_DIR in test-functions, remove from other scripts
The $BUILD_DIR is only used in test-functions, and doesn't need to
be specified in any other scripts. Additionally, to be able to allow
the integration test suite to be run against locally installed binaries,
instead of built binaries, moving BUILD_DIR logic completely into
test-functions allows later patches to be simpler.
2021-01-26 17:09:48 -05:00
Luca Boccassi
74eec54d66 test: note where the bionic-* CI tool/integration lives 2021-01-24 12:03:53 +00:00
Luca Boccassi
eb3785f367 tests: add TEST_PREFER_NSPAWN variable to run as many as possible under nspawn
By default the test suite prefers qemu, and uses nspawn only if
a test specifically says it doesn't support qemu.
Add a variable to allow flipping the default, and run as many
tests under nspawn as possible.
2021-01-01 21:33:16 +00:00
Luca Boccassi
51d56d3be0 tests: add TEST_QEMU_ONLY variable to run only tests where qemu is mandatory
Allows to split the test run in two parts. Most tests can run under
nspawn which is much faster, and they can be ran in one chunk with
TEST_NO_QEMU=1. The qemu-only tests, which are just a handful, can
be ran in another chunk with TEST_QEMU_ONLY=1.

Allows autopkgtest to be split in two parts.
2021-01-01 21:33:16 +00:00
Luca Boccassi
964523e6c2 test/README: notes about Ubuntu CI logs and dependencies
Add a note about where to find the full journal, and how to add
packages/dependencies for the Ubuntu CI.
2020-10-17 17:58:40 +01:00
Dan Streetman
825cba0d43 test: convert ubuntu-ci to use deny-list
Follows #16262
2020-08-01 15:36:35 +02:00
Zbigniew Jędrzejewski-Szmek
8af10ca3fc test: print test of name in output 2020-03-28 12:37:28 +01:00
Zbigniew Jędrzejewski-Szmek
46c41478c9 tree-wise: standarize on "auto-detection" spelling 2019-11-30 17:42:13 +01:00
Dan Streetman
b4532d650b test/README.testsuite: add section for Ubuntu CI blacklist files
Add some docs explaining how blacklist individual test/TEST-*
tests in Ubuntu CI using per-test blacklist files.
2019-10-03 11:01:23 -04:00
Frantisek Sumsal
501deda1ce test: allow use of nested KVM
Introduce TEST_NESTED_KVM variable, which allows use of nested KVM for
QEMU VMs (which is disabled by default by KVM autodetection).
2019-09-27 15:42:38 -07:00
Frantisek Sumsal
5a2114b60e test: improve testsuite configuration documentation 2019-03-16 18:59:07 +01:00
Zbigniew Jędrzejewski-Szmek
64d14b7e23 README.testsuite: update the documentation for meson 2018-10-09 15:31:00 +02:00
Chris Lamb
04e599b1ce test: explain why we explicitly make all despite test/Makefile's check target calling it (#5830) 2017-04-29 08:23:13 +02:00
Evgeny Vereshchagin
61fea35e14 tests: fix initrd searching on Debian/Ubuntu 2015-11-20 12:10:12 +00:00
Kay Sievers
2375607039 remove gudev and gtk-doc
The library moved to:
  https://git.gnome.org/browse/libgudev/
2015-06-03 00:22:53 +02:00
Ronny Chevalier
c6a77179a4 test: rework run_qemu
It tries to find a suitable QEMU binary and will use KVM if present.
We can now configure QEMU from outside with 4 variables :
  - $QEMU_BIN : path to QEMU's binary
  - $KERNEL_APPEND : arguments appended to kernel cmdline
  - $KERNEL_BIN : path to a kernel
    Default /boot/vmlinuz-$KERNEL_VER
  - $INITRD : path to an initramfs
    Default /boot/initramfs-${KERNEL_VER}.img
  - $QEMU_SMP : number of CPU simulated by QEMU.
    Default 1

(from Alexander Graf's script: http://www.spinics.net/lists/kvm/msg72389.html)
2013-12-10 07:46:21 -05:00
Zbigniew Jędrzejewski-Szmek
7bcd865d38 test: some trivial fixes to test scripts
- fix typo
- use compiled systemd-nspawn
- drop --capability=... from systemd-nspawn invocation, is is the default now
- simplify sudo make invocations
2013-01-29 19:01:41 -05:00
Harald Hoyer
c452e37254 test/README.testsuite: add documentation for the testsuite 2012-05-29 09:23:37 +02:00