summaryrefslogtreecommitdiffstats
path: root/test (follow)
Commit message (Collapse)AuthorAgeFilesLines
* test: increase the timeout for hwdb-testZbigniew Jędrzejewski-Szmek2017-11-261-1/+2
| | | | | This test does a lot of mmap/madvise/unmmap, which is slow under address sanitizer. Just increase the timeout to avoid spurious failure.
* test: set log_level to info in test-hwdb and check-help-*Yu Watanabe2017-11-251-0/+1
| | | | | | | | | | These tests check the stderr. So, if the systemd.log_level=debug is set in the kernel command line, then these tests fail. This set log_level to info in hwdb-test.sh and meson-check-help.sh, the kernel command line not to change the output of the target programs. Fixes #7362.
* test: skip DELEGATE test if the kernel can't do cgroupv2 (#7445)Lennart Poettering2017-11-241-8/+12
| | | Fixes: #7440
* test-execute: test more % specifiers (#7450)Yu Watanabe2017-11-243-3/+31
|
* tests: install `test` as part of BASICTOOLS (#7434)Evgeny Vereshchagin2017-11-231-1/+1
| | | | | This makes TEST-19-DELEGATE, which is currently failing, work. Closes https://github.com/systemd/systemd/issues/7425.
* meson: re-attach rule-syntax-check.py testZbigniew Jędrzejewski-Szmek2017-11-222-11/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 39/248 rule-syntax-check OK 0.07 s --- command --- /home/zbyszek/src/systemd-work/test/rule-syntax-check.py \ /home/zbyszek/src/systemd-work/build/../rules/60-block.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-cdrom_id.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-drm.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-evdev.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-input-id.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-persistent-alsa.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-persistent-input.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-persistent-storage.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-persistent-storage-tape.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-persistent-v4l.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-sensor.rules \ /home/zbyszek/src/systemd-work/build/../rules/60-serial.rules \ /home/zbyszek/src/systemd-work/build/../rules/70-joystick.rules \ /home/zbyszek/src/systemd-work/build/../rules/70-mouse.rules \ /home/zbyszek/src/systemd-work/build/../rules/70-touchpad.rules \ /home/zbyszek/src/systemd-work/build/../rules/75-net-description.rules \ /home/zbyszek/src/systemd-work/build/../rules/75-probe_mtd.rules \ /home/zbyszek/src/systemd-work/build/../rules/78-sound-card.rules \ /home/zbyszek/src/systemd-work/build/../rules/80-drivers.rules \ /home/zbyszek/src/systemd-work/build/../rules/80-net-setup-link.rules \ /home/zbyszek/src/systemd-work/build/rules/50-udev-default.rules \ /home/zbyszek/src/systemd-work/build/rules/64-btrfs.rules \ /home/zbyszek/src/systemd-work/build/rules/99-systemd.rules --- stdout --- ... ------- It got dropped by mistake in 72cdb3e783174dcf9223a49f03e3b0e2ca95ddb8.
* rule-test-syntax: modernize syntax and add debug messageZbigniew Jędrzejewski-Szmek2017-11-221-4/+5
|
* Merge pull request #7381 from poettering/cgroup-unified-delegate-reworkZbigniew Jędrzejewski-Szmek2017-11-223-0/+67
|\ | | | | Fix delegation in the unified hierarchy + more cgroup work
| * test: fix UDEV-WANTS testcase for non-bash shellsLennart Poettering2017-11-211-1/+1
| | | | | | | | | | testsuite.sh uses "set -o pipefile", which is a bashism, hence use bash to invoke the script.
| * test: add a test case that validates cgroup delegationLennart Poettering2017-11-213-0/+67
| | | | | | | | | | | | This test runs on the unified hierarchy, and ensures that cgroup delegation works properly, i.e. writ access is granted and the requested controllers are enabled.
* | test: fix UDEV-WANTS testcase for non-bash shells (#7407)Lennart Poettering2017-11-211-1/+1
| | | | | | | | testsuite.sh uses "set -o pipefile", which is a bashism, hence use bash to invoke the script.
* | Merge pull request #7363 from poettering/success-actionLennart Poettering2017-11-214-1/+65
|\ \ | |/ |/| Generalize FailureAction=, and add SuccessAction=
| * test: add testcase for FailureAction=/SuccessAction=Lennart Poettering2017-11-204-1/+65
| | | | | | | | it also ensures that rebooting once gets us back up. Yay!
* | test: fall back to /boot if bootctl -p fails (#7397)Zbigniew Jędrzejewski-Szmek2017-11-201-1/+1
|/ | | It doesn't really matter why.
* Merge pull request #7154 from keszybz/bootspecLennart Poettering2017-11-201-4/+5
|\ | | | | List bootspec entries in bootctl and use the default for kexec
| * test: do not hardcode location of EFI partitionZbigniew Jędrzejewski-Szmek2017-11-191-4/+5
| |
* | Merge pull request #7198 from poettering/stdin-stdoutLennart Poettering2017-11-193-0/+28
|\ \ | | | | | | Add StandardInput=data, StandardInput=file:... and more
| * | test: add basic test for StandardInput=file:Lennart Poettering2017-11-173-1/+9
| | |
| * | test: add tests for StandardInputText= and StandardInputData=Lennart Poettering2017-11-172-0/+20
| | |
* | | Add license headers and SPDX identifiers to meson.build filesZbigniew Jędrzejewski-Szmek2017-11-191-0/+17
| | | | | | | | | | | | | | | | | | | | | So far I avoided adding license headers to meson files, but they are pretty big and important and should carry license headers like everything else. I added my own copyright, even though other people modified those files too. But this is mostly symbolic, so I hope that's OK.
* | | Add SPDX license headers to various assorted filesZbigniew Jędrzejewski-Szmek2017-11-191-2/+4
| | |
* | | Add SPDX license headers to python scriptsZbigniew Jędrzejewski-Szmek2017-11-196-1/+8
|/ /
* | Merge pull request #7186 from poettering/track-depsZbigniew Jędrzejewski-Szmek2017-11-123-0/+129
|\ \ | | | | | | rework unit dependency data structure to track why deps get created
| * | test: add test case for adding/removing dependencies via udev rulesLennart Poettering2017-11-103-0/+129
| | |
* | | test-execute: change path to python3 (#7306)Yu Watanabe2017-11-124-4/+4
| | | | | | | | | | | | | | | | | | Change python3 path from /bin/python3 to /usr/bin/python3 to make the test work on Ubuntu Xenial. Follow-up for #7178.
* | | test-execute: update test for SystemCallErrorNumber=Yu Watanabe2017-11-113-2/+11
| | |
* | | test: add tests for syscall:errno style in SystemCallFilter=Yu Watanabe2017-11-113-0/+18
|/ /
* | test: add test for ReadOnlyPaths= with RuntimeDirectory=Yu Watanabe2017-11-082-0/+10
| |
* | test: switch to using ext4 instead of ext3 as default fallback fs (#7265)Dimitri John Ledkov2017-11-072-3/+3
| | | | | | | | Using ext3 is not representative anymore, and Ubuntu has stopped shipping fsck.ext3 in the initramfs.
* | journalctl: add --output-fields= (#7181)Lars Karlitski2017-10-271-0/+12
| | | | | | | | | | | | | | | | | | This option allows restricting the shown fields in the output modes that would normally show all fields. It allows clients that are only interested in a subset of the fields to access those more efficiently. Also, it makes the resulting size of the output more predictable. It has no effect on the various `short` output modes, because those already only show a subset of the fields.
* | test: add simple test for validating some of the unit specifiers we supportLennart Poettering2017-10-262-87/+103
|/ | | | | (Also, sort list of test unit files in meson.build alphabetically, to make future additions more systematic)
* test-execute: always use /bin/shYu Watanabe2017-10-128-17/+17
|
* test: add test for BindPaths= and BindReadOnlyPaths=Yu Watanabe2017-10-122-0/+15
| | | | Follow-up for a8cabc612b16834260831a8163ae4b479b5c33a5.
* test: skip hwdb and sysv-generator if the features are disabled (#7026)Mike Gilbert2017-10-081-6/+10
|
* build-sys: s/ENABLE_RESOLVED/ENABLE_RESOLVE/Zbigniew Jędrzejewski-Szmek2017-10-041-1/+1
| | | | | | The configuration option was called -Dresolve, but the internal define was …RESOLVED. This options governs more than just resolved itself, so let's settle on the version without "d".
* build-sys: use #if Y instead of #ifdef Y everywhereZbigniew Jędrzejewski-Szmek2017-10-041-1/+1
| | | | | | | | | | | | | | | The advantage is that is the name is mispellt, cpp will warn us. $ git grep -Ee "conf.set\('(HAVE|ENABLE)_" -l|xargs sed -r -i "s/conf.set\('(HAVE|ENABLE)_/conf.set10('\1_/" $ git grep -Ee '#ifn?def (HAVE|ENABLE)' -l|xargs sed -r -i 's/#ifdef (HAVE|ENABLE)/#if \1/; s/#ifndef (HAVE|ENABLE)/#if ! \1/;' $ git grep -Ee 'if.*defined\(HAVE' -l|xargs sed -i -r 's/defined\((HAVE_[A-Z0-9_]*)\)/\1/g' $ git grep -Ee 'if.*defined\(ENABLE' -l|xargs sed -i -r 's/defined\((ENABLE_[A-Z0-9_]*)\)/\1/g' + manual changes to meson.build squash! build-sys: use #if Y instead of #ifdef Y everywhere v2: - fix incorrect setting of HAVE_LIBIDN2
* test: add test for DynamicUser= + StateDirectory=Lennart Poettering2017-10-022-0/+20
| | | | | | | | | | | Also, tests for DynamicUser= should really run for system mode, as we allocate from a system resource. (This also increases the test timeout to 2min. If one of our tests really hangs then waiting for 2min longer doesn't hurt either. The old 2s is really short, given that we run in potentially slow VM environments for this test. This becomes noticable when the slow "find" command this adds is triggered)
* sys-script: remove output directory if it existsZbigniew Jędrzejewski-Szmek2017-09-292-0/+6
| | | | | meson will occasionally call us even though the output directory exists. Let's just nuke and recreate in that case.
* create-sys-script: adapt to separate build dir, modernize, add more checksZbigniew Jędrzejewski-Szmek2017-09-292-24/+28
| | | | | | | | | The script wasn't apparently used since the switch to meson, because it required the sys subdirectory to be present in the same subdirectory where the output script is located. Let's use f-strings to make the whole thing more readable. Add some extra checks.
* udev-rules: all values can contain escaped double quotes now (#6890)Franck Bui2017-09-281-0/+24
| | | | | | | | | | | | | | | | | This is primarly useful to support escaped double quotes in PROGRAM or IMPORT{program} directives. The only possibilty before this patch was to use an external shell script but this seems too cumbersome for trivial logics such as PROGRAM=="/bin/sh -c 'FOO=\"%s{model}\"; echo ${FOO:0:4}'" or any similar shell constructs that needs to deals with patterns including whitespaces. As it's the case for single quote and for directives running a program, words within escaped double quotes will be considered as a single argument. Fixes: #6835
* meson: hook up hwdb-test.sh againZbigniew Jędrzejewski-Szmek2017-09-262-1/+5
| | | | | The motivation for the ./systemd-hwdb is the same as in the grandparent for systemd-sysv-generator.
* meson: hook up udev-test.pl againZbigniew Jędrzejewski-Szmek2017-09-261-0/+14
| | | | | Seems it was dropped along with the automake rules in 72cdb3e783174dcf9223a49f03e3b0e2ca95ddb8.
* sysv-generator-test: do not query $builddirZbigniew Jędrzejewski-Szmek2017-09-261-1/+1
| | | | | | | | | | This variable is not set by meson, so let's not try to use it. We could use some more elaborate scheme (e.g. based on $MESON_BUILD_ROOT and $MESON_SUBDIR) to find the path to systemd-sysv-generator, but it seems that plain ./systemd-sysv-generator works just as well and has the advantage that it's easy to invoke the test by hand (as long as one cd's to the meson build dir).
* sysv-generator-test: drop python2 work-aroundZbigniew Jędrzejewski-Szmek2017-09-261-6/+1
| | | | | We require python3 for meson anyway, so support python2 doesn't seem useful anymore.
* test: add test case for UnsetEnvironment=Lennart Poettering2017-09-142-0/+9
|
* test: drop Exec* prefixes to obtain paths of executablesYu Watanabe2017-08-302-2/+2
|
* service: attempt to execute next main command only for oneshot services (#6619)Michal Sekletar2017-08-251-0/+31
| | | | | | | | | | | | | | This commit fixes crash described in https://github.com/systemd/systemd/issues/6533 Multiple ExecStart lines are allowed only for oneshot services anyway so it doesn't make sense to call service_run_next_main() with services of type other than SERVICE_ONESHOT. Referring back to reproducer from the issue, previously we didn't observe this problem because s->main_command was reset after daemon-reload hence we never reached the assert statement in service_run_next_main(). Fixes #6533
* test: Run qemu/nspawn tests with "set -e"Martin Pitt2017-08-1017-38/+51
| | | | | | | | This catches errors like "ninja not found", missing programs etc. early, instead of silently ignoring them and trying to boot a broken VM. In install_config_files(), allow some distro specific files to be absent (such as /etc/sysconfig/init).
* test: Write state and log files into $BUILD_DIRMartin Pitt2017-08-101-6/+11
| | | | | This avoids clobbering the source tree with .testdir/test.log files and makes the tests work in situations where the source tree is read-only.
* tests: use ninja-build if ninja is not available (#6544)Evgeny Vereshchagin2017-08-071-1/+6
| | | | This makes the tests work on CentOS, which currently has ninja-build only.