Skip to content

Commit

Permalink
test: install integration-test-setup.sh in testdata/
Browse files Browse the repository at this point in the history
integration-test-setup.sh is an auxiliary script that tests rely on at
runtime. As such, install the script in testdata/.

Follow-up for af153e3.
fbuihuu authored and DaanDeMeyer committed Nov 8, 2024
1 parent b480a4c commit 514d9e1
Showing 2 changed files with 9 additions and 7 deletions.
12 changes: 7 additions & 5 deletions test/meson.build
Original file line number Diff line number Diff line change
@@ -142,11 +142,13 @@ endif
############################################################

if install_tests
foreach script : ['integration-test-setup.sh', 'run-unit-tests.py']
install_data(script,
install_mode : 'rwxr-xr-x',
install_dir : testsdir)
endforeach
install_data('run-unit-tests.py',
install_mode : 'rwxr-xr-x',
install_dir : testsdir)

install_data('integration-test-setup.sh',
install_mode : 'rwxr-xr-x',
install_dir : testdata_dir)
endif

############################################################
4 changes: 2 additions & 2 deletions test/test.service.in
Original file line number Diff line number Diff line change
@@ -7,9 +7,9 @@ Before=getty-pre.target

[Service]
ExecStartPre=rm -f /failed /testok
ExecStartPre=/usr/lib/systemd/tests/integration-test-setup.sh setup
ExecStartPre=/usr/lib/systemd/tests/testdata/integration-test-setup.sh setup
ExecStart=@command@
ExecStopPost=/usr/lib/systemd/tests/integration-test-setup.sh finalize
ExecStopPost=/usr/lib/systemd/tests/testdata/integration-test-setup.sh finalize
Type=oneshot
MemoryAccounting=@memory-accounting@
StateDirectory=%N

0 comments on commit 514d9e1

Please sign in to comment.