Skip to content

Commit b71217c

Browse files
committed
meson: add 'raw' test suite
The 'raw' test suite runs each compiled test without the runtest*.sh wrapper scripts. This is useful to debug tests using meson's gdb support. To debug a test in gdb run `meson test -C build --suite=raw <testname>_raw` Signed-off-by: Florian Fischer <[email protected]>
1 parent beb1279 commit b71217c

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

test/meson.build

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -174,15 +174,15 @@ foreach test_source: all_tests
174174
# using the meson filesystem module would solve this restriction
175175
# but require to bump our minimum meson version to '>= 0.54'.
176176
test_name = test_source.split()[0]
177-
executable(test_name,
178-
[test_source, 'helpers.c'],
179-
c_args: xcflags,
180-
cpp_args: xcflags,
181-
include_directories: liburing_internal_includes,
182-
link_with: liburing.get_static_lib(),
183-
dependencies: test_dependencies,
184-
install: true,
185-
install_dir: get_option('datadir') / 'liburing-test')
177+
test_exe = executable(test_name,
178+
[test_source, 'helpers.c'],
179+
c_args: xcflags,
180+
cpp_args: xcflags,
181+
include_directories: liburing_internal_includes,
182+
link_with: liburing.get_static_lib(),
183+
dependencies: test_dependencies,
184+
install: true,
185+
install_dir: get_option('datadir') / 'liburing-test')
186186

187187
test(test_name,
188188
runtests_sh,
@@ -203,6 +203,10 @@ foreach test_source: all_tests
203203
args: test_name,
204204
workdir: meson.current_build_dir(),
205205
suite: 'parallel')
206+
207+
test(test_name + '_raw',
208+
test_exe,
209+
suite: 'raw')
206210
endforeach
207211

208212
if meson.version().version_compare('>=0.57')

0 commit comments

Comments
 (0)