If we're not running interactively, there's no point in the features
from integration-test-setup.sh which are intended for interactive
development and debugging so lets skip adding it in that case.
"""
)
+ if sys.stderr.isatty():
+ dropin += textwrap.dedent(
+ """
+ [Service]
+ ExecStartPre=/usr/lib/systemd/tests/testdata/integration-test-setup.sh setup
+ ExecStopPost=/usr/lib/systemd/tests/testdata/integration-test-setup.sh finalize
+ """
+ )
+
cmd = [
args.mkosi,
'--directory', os.fspath(args.meson_source_dir),
[Service]
ExecStartPre=rm -f /failed /testok
-ExecStartPre=/usr/lib/systemd/tests/testdata/integration-test-setup.sh setup
ExecStart=@command@
-ExecStopPost=/usr/lib/systemd/tests/testdata/integration-test-setup.sh finalize
Type=oneshot
MemoryAccounting=@memory-accounting@
StateDirectory=%N