]> git.ipfire.org Git - thirdparty/systemd.git/blob - test/meson.build
test-execute: rename tests for AmbientCapabilities=
[thirdparty/systemd.git] / test / meson.build
1 # SPDX-License-Identifier: LGPL-2.1+
2 #
3 # Copyright 2017 Zbigniew Jędrzejewski-Szmek
4 #
5 # systemd is free software; you can redistribute it and/or modify it
6 # under the terms of the GNU Lesser General Public License as published by
7 # the Free Software Foundation; either version 2.1 of the License, or
8 # (at your option) any later version.
9 #
10 # systemd is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 # Lesser General Public License for more details.
14 #
15 # You should have received a copy of the GNU Lesser General Public License
16 # along with systemd; If not, see <http://www.gnu.org/licenses/>.
17
18 test_data_files = '''
19 a.service
20 b.service
21 basic.target
22 c.service
23 d.service
24 daughter.service
25 e.service
26 end.service
27 f.service
28 g.service
29 grandchild.service
30 h.service
31 hello-after-sleep.target
32 hello.service
33 hwdb/10-bad.hwdb
34 journal-data/journal-1.txt
35 journal-data/journal-2.txt
36 parent-deep.slice
37 parent.slice
38 sched_idle_bad.service
39 sched_idle_ok.service
40 sched_rr_bad.service
41 sched_rr_change.service
42 sched_rr_ok.service
43 shutdown.target
44 sleep.service
45 sockets.target
46 son.service
47 sysinit.target
48 test-execute/exec-ambientcapabilities-merge-nfsnobody.service
49 test-execute/exec-ambientcapabilities-merge-nobody.service
50 test-execute/exec-ambientcapabilities-merge.service
51 test-execute/exec-ambientcapabilities-nfsnobody.service
52 test-execute/exec-ambientcapabilities-nobody.service
53 test-execute/exec-ambientcapabilities.service
54 test-execute/exec-bindpaths.service
55 test-execute/exec-capabilityboundingset-invert.service
56 test-execute/exec-capabilityboundingset-merge.service
57 test-execute/exec-capabilityboundingset-reset.service
58 test-execute/exec-capabilityboundingset-simple.service
59 test-execute/exec-cpuaffinity1.service
60 test-execute/exec-cpuaffinity2.service
61 test-execute/exec-cpuaffinity3.service
62 test-execute/exec-dynamicuser-fixeduser-one-supplementarygroup.service
63 test-execute/exec-dynamicuser-fixeduser.service
64 test-execute/exec-dynamicuser-statedir-migrate-step1.service
65 test-execute/exec-dynamicuser-statedir-migrate-step2.service
66 test-execute/exec-dynamicuser-statedir.service
67 test-execute/exec-dynamicuser-supplementarygroups.service
68 test-execute/exec-environment-empty.service
69 test-execute/exec-environment-multiple.service
70 test-execute/exec-environment.service
71 test-execute/exec-environmentfile.service
72 test-execute/exec-group-nfsnobody.service
73 test-execute/exec-group-nobody.service
74 test-execute/exec-group-nogroup.service
75 test-execute/exec-group.service
76 test-execute/exec-ignoresigpipe-no.service
77 test-execute/exec-ignoresigpipe-yes.service
78 test-execute/exec-inaccessiblepaths-mount-propagation.service
79 test-execute/exec-inaccessiblepaths-proc.service
80 test-execute/exec-ioschedulingclass-best-effort.service
81 test-execute/exec-ioschedulingclass-idle.service
82 test-execute/exec-ioschedulingclass-none.service
83 test-execute/exec-ioschedulingclass-realtime.service
84 test-execute/exec-oomscoreadjust-negative.service
85 test-execute/exec-oomscoreadjust-positive.service
86 test-execute/exec-passenvironment-absent.service
87 test-execute/exec-passenvironment-empty.service
88 test-execute/exec-passenvironment-repeated.service
89 test-execute/exec-passenvironment.service
90 test-execute/exec-personality-aarch64.service
91 test-execute/exec-personality-ppc64.service
92 test-execute/exec-personality-ppc64le.service
93 test-execute/exec-personality-s390.service
94 test-execute/exec-personality-x86-64.service
95 test-execute/exec-personality-x86.service
96 test-execute/exec-privatedevices-no-capability-mknod.service
97 test-execute/exec-privatedevices-no-capability-sys-rawio.service
98 test-execute/exec-privatedevices-no.service
99 test-execute/exec-privatedevices-yes-capability-mknod.service
100 test-execute/exec-privatedevices-yes-capability-sys-rawio.service
101 test-execute/exec-privatedevices-yes.service
102 test-execute/exec-privatenetwork-yes.service
103 test-execute/exec-privatetmp-no.service
104 test-execute/exec-privatetmp-yes.service
105 test-execute/exec-protectkernelmodules-no-capabilities.service
106 test-execute/exec-protectkernelmodules-yes-capabilities.service
107 test-execute/exec-protectkernelmodules-yes-mount-propagation.service
108 test-execute/exec-readonlypaths-mount-propagation.service
109 test-execute/exec-readonlypaths-simple.service
110 test-execute/exec-readonlypaths-with-bindpaths.service
111 test-execute/exec-readonlypaths.service
112 test-execute/exec-readwritepaths-mount-propagation.service
113 test-execute/exec-restrictnamespaces-mnt-blacklist.service
114 test-execute/exec-restrictnamespaces-mnt.service
115 test-execute/exec-restrictnamespaces-no.service
116 test-execute/exec-restrictnamespaces-yes.service
117 test-execute/exec-runtimedirectory-mode.service
118 test-execute/exec-runtimedirectory-owner-nfsnobody.service
119 test-execute/exec-runtimedirectory-owner-nobody.service
120 test-execute/exec-runtimedirectory-owner-nogroup.service
121 test-execute/exec-runtimedirectory-owner.service
122 test-execute/exec-runtimedirectory.service
123 test-execute/exec-specifier-interpolation.service
124 test-execute/exec-specifier.service
125 test-execute/exec-specifier@.service
126 test-execute/exec-standardinput-data.service
127 test-execute/exec-standardinput-file.service
128 test-execute/exec-supplementarygroups-multiple-groups-default-group-user.service
129 test-execute/exec-supplementarygroups-multiple-groups-withgid.service
130 test-execute/exec-supplementarygroups-multiple-groups-withuid.service
131 test-execute/exec-supplementarygroups-single-group-user.service
132 test-execute/exec-supplementarygroups-single-group.service
133 test-execute/exec-supplementarygroups.service
134 test-execute/exec-systemcallerrornumber-name.service
135 test-execute/exec-systemcallerrornumber-number.service
136 test-execute/exec-systemcallfilter-failing.service
137 test-execute/exec-systemcallfilter-failing2.service
138 test-execute/exec-systemcallfilter-not-failing.service
139 test-execute/exec-systemcallfilter-not-failing2.service
140 test-execute/exec-systemcallfilter-system-user-nfsnobody.service
141 test-execute/exec-systemcallfilter-system-user-nobody.service
142 test-execute/exec-systemcallfilter-system-user.service
143 test-execute/exec-systemcallfilter-with-errno-name.service
144 test-execute/exec-systemcallfilter-with-errno-number.service
145 test-execute/exec-temporaryfilesystem-options.service
146 test-execute/exec-temporaryfilesystem-ro.service
147 test-execute/exec-temporaryfilesystem-rw.service
148 test-execute/exec-temporaryfilesystem-usr.service
149 test-execute/exec-umask-0177.service
150 test-execute/exec-umask-default.service
151 test-execute/exec-unsetenvironment.service
152 test-execute/exec-user-nfsnobody.service
153 test-execute/exec-user-nobody.service
154 test-execute/exec-user.service
155 test-execute/exec-workingdirectory.service
156 test-path/basic.target
157 test-path/path-changed.path
158 test-path/path-changed.service
159 test-path/path-directorynotempty.path
160 test-path/path-directorynotempty.service
161 test-path/path-exists.path
162 test-path/path-exists.service
163 test-path/path-existsglob.path
164 test-path/path-existsglob.service
165 test-path/path-makedirectory.path
166 test-path/path-makedirectory.service
167 test-path/path-modified.path
168 test-path/path-modified.service
169 test-path/path-mycustomunit.service
170 test-path/path-service.service
171 test-path/path-unit.path
172 test-path/paths.target
173 test-path/sysinit.target
174 testsuite.target
175 timers.target
176 unstoppable.service
177 '''.split()
178
179 if conf.get('ENABLE_RESOLVE') == 1
180 test_data_files += '''
181 test-resolve/_openpgpkey.fedoraproject.org.pkts
182 test-resolve/fedoraproject.org.pkts
183 test-resolve/gandi.net.pkts
184 test-resolve/google.com.pkts
185 test-resolve/root.pkts
186 test-resolve/sw1a1aa-sw1a2aa-sw1a2ab-sw1a2ac.find.me.uk.pkts
187 test-resolve/teamits.com.pkts
188 test-resolve/zbyszek@fedoraproject.org.pkts
189 test-resolve/_443._tcp.fedoraproject.org.pkts
190 test-resolve/kyhwana.org.pkts
191 test-resolve/fake-caa.pkts
192 '''.split()
193 endif
194
195 if install_tests
196 foreach file : test_data_files
197 subdir = file.split('/')[0]
198 if subdir == file
199 subdir = ''
200 endif
201
202 install_data(file,
203 install_dir : testsdir + '/testdata/' + subdir)
204 endforeach
205 endif
206
207 ############################################################
208
209 rule_syntax_check_py = find_program('rule-syntax-check.py')
210 test('rule-syntax-check',
211 rule_syntax_check_py,
212 args : all_rules)
213
214 ############################################################
215
216 if conf.get('HAVE_SYSV_COMPAT') == 1
217 sysv_generator_test_py = find_program('sysv-generator-test.py')
218 test('sysv-generator-test',
219 sysv_generator_test_py)
220 endif
221
222 ############################################################
223
224 # prepare test/sys tree
225 sys_script_py = find_program('sys-script.py')
226 custom_target(
227 'sys',
228 command : [sys_script_py, meson.current_build_dir()],
229 output : 'sys',
230 build_by_default : true)
231
232 udev_test_pl = find_program('udev-test.pl')
233 test('udev-test',
234 udev_test_pl)
235
236 if conf.get('ENABLE_HWDB') == 1
237 hwdb_test_sh = find_program('hwdb-test.sh')
238 test('hwdb-test',
239 hwdb_test_sh,
240 timeout : 90)
241 endif
242
243 subdir('fuzz-regressions')