Skip to content

Commit 1d9b8f3

Browse files
committed
test: Only add tpm2.target dependency to TEST-70-TPM2.service
Let's not add the dependency unless required.
1 parent 7273d16 commit 1d9b8f3

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

test/TEST-70-TPM2/meson.build

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,9 @@
33
integration_tests += [
44
integration_test_template + {
55
'name' : fs.name(meson.current_source_dir()),
6+
'configuration' : integration_test_template['configuration'] + {
7+
'wants' : '@0@ tpm2.target'.format(integration_test_template['configuration']['wants']),
8+
'after' : '@0@ tpm2.target'.format(integration_test_template['configuration']['after']),
9+
},
610
},
711
]

test/meson.build

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,8 @@ integration_test_template = {
286286
'configuration' : {
287287
'memory-accounting' : 'no',
288288
'command' : testdata_dir / 'units/%N.sh',
289+
'wants' : '',
290+
'after' : '',
289291
},
290292
'cmdline' : [],
291293
}

test/test.service.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# SPDX-License-Identifier: LGPL-2.1-or-later
22
[Unit]
33
Description=%N
4-
Wants=basic.target network.target tpm2.target multi-user.target [email protected]
5-
After=basic.target network.target tpm2.target [email protected]
4+
Wants=basic.target network.target multi-user.target [email protected] @wants@
5+
After=basic.target network.target [email protected] @after@
66
Before=getty-pre.target
77

88
[Service]

0 commit comments

Comments
 (0)