Skip to content

Commit 48976e5

Browse files
committed
test: add a workaround for rth invocation
The `rth` tool is a python script and relied on the execution via the shebang. However, not all targets support the shebang to invoke the interpreter. Explicitly launch the resilience test helper with the interpreter (python). Ideally, we would use the `%rth` substitution, but that does not seem to function for the nested case here.
1 parent 5fa42c0 commit 48976e5

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

test/lit.cfg

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1338,12 +1338,13 @@ rth_flags = ''
13381338
if swift_execution_tests_extra_flags:
13391339
rth_flags = swift_execution_tests_extra_flags + ' -wmo'
13401340

1341+
# FIXME: why can we not use %rth and have that be expanded out?
13411342
config.target_resilience_test = (
1342-
'%s --target-build-swift "%s" --target-run "%s" --t %%t --S %%S --s %%s '
1343-
'--lib-prefix "%s" --lib-suffix "%s" --target-codesign "%s" '
1343+
'%r %s --target-build-swift "%s" --target-run "%s" --t %%t --S %%S '
1344+
'--s %%s --lib-prefix "%s" --lib-suffix "%s" --target-codesign "%s" '
13441345
'--additional-compile-flags "%s" --triple "%s"'
1345-
% (config.rth, config.target_build_swift, config.target_run,
1346-
config.target_shared_library_prefix,
1346+
% (sys.executable, config.rth, config.target_build_swift,
1347+
config.target_run, config.target_shared_library_prefix,
13471348
config.target_shared_library_suffix, config.target_codesign,
13481349
rth_flags, config.variant_triple))
13491350

0 commit comments

Comments
 (0)