test: Only add tpm2.target dependency to TEST-70-TPM2.service

Let's not add the dependency unless required.
This commit is contained in:
Daan De Meyer 2024-05-14 15:35:59 +02:00
parent 7273d16022
commit 1d9b8f3476
3 changed files with 8 additions and 2 deletions

View file

@ -3,5 +3,9 @@
integration_tests += [
integration_test_template + {
'name' : fs.name(meson.current_source_dir()),
'configuration' : integration_test_template['configuration'] + {
'wants' : '@0@ tpm2.target'.format(integration_test_template['configuration']['wants']),
'after' : '@0@ tpm2.target'.format(integration_test_template['configuration']['after']),
},
},
]

View file

@ -286,6 +286,8 @@ integration_test_template = {
'configuration' : {
'memory-accounting' : 'no',
'command' : testdata_dir / 'units/%N.sh',
'wants' : '',
'after' : '',
},
'cmdline' : [],
}

View file

@ -1,8 +1,8 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
[Unit]
Description=%N
Wants=basic.target network.target tpm2.target multi-user.target user@4711.service
After=basic.target network.target tpm2.target user@4711.service
Wants=basic.target network.target multi-user.target user@4711.service @wants@
After=basic.target network.target user@4711.service @after@
Before=getty-pre.target
[Service]