summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJan Janssen <medhefgo@web.de>2023-06-14 16:05:52 +0200
committerJan Janssen <medhefgo@web.de>2023-06-14 16:05:52 +0200
commit739a62bb40695addd1d118eadbab4ec47aa24db5 (patch)
treef73344a71542e2049ab9bece6a9b458d8644c98b /test
parentsleep-config: add comment about security (diff)
downloadsystemd-739a62bb40695addd1d118eadbab4ec47aa24db5.tar.xz
systemd-739a62bb40695addd1d118eadbab4ec47aa24db5.zip
meson: Use fs module in more places
Diffstat (limited to '')
-rw-r--r--test/fuzz/meson.build4
-rw-r--r--test/meson.build4
2 files changed, 3 insertions, 5 deletions
diff --git a/test/fuzz/meson.build b/test/fuzz/meson.build
index a8fb71c566..61a62a75a3 100644
--- a/test/fuzz/meson.build
+++ b/test/fuzz/meson.build
@@ -83,8 +83,8 @@ foreach p : out.stdout().split()
if p.contains('\\')
continue
endif
- fuzzer = p.split('/')[-2]
- fuzz_in = p.split('/')[-1]
+ fuzzer = fs.name(fs.parent(p))
+ fuzz_in = fs.name(p)
if fuzzer not in fuzz_regression_tests
fuzz_regression_tests += {fuzzer: []}
endif
diff --git a/test/meson.build b/test/meson.build
index 0b0a32c0d1..a049750116 100644
--- a/test/meson.build
+++ b/test/meson.build
@@ -155,9 +155,7 @@ if want_tests != 'false' and dmi_arches.contains(host_machine.cpu_family())
foreach p : out.stdout().split()
source = project_source_root / p
- name = 'dmidecode_' + p.split('/')[-1].split('.')[0]
-
- test(name,
+ test('dmidecode_' + fs.stem(p),
udev_dmi_memory_id_test,
suite : 'dist',
args : [udev_prog_paths['dmi_memory_id'].full_path(),