summaryrefslogtreecommitdiffstats
path: root/test/testsuite-28.units
diff options
context:
space:
mode:
Diffstat (limited to 'test/testsuite-28.units')
-rw-r--r--test/testsuite-28.units/specifier-j-depends-wants.service8
-rw-r--r--test/testsuite-28.units/specifier-j-wants.service11
-rw-r--r--test/testsuite-28.units/testsuite-28-pre.service4
3 files changed, 23 insertions, 0 deletions
diff --git a/test/testsuite-28.units/specifier-j-depends-wants.service b/test/testsuite-28.units/specifier-j-depends-wants.service
new file mode 100644
index 0000000..c39a8ba
--- /dev/null
+++ b/test/testsuite-28.units/specifier-j-depends-wants.service
@@ -0,0 +1,8 @@
+# SPDX-License-Identifier: LGPL-2.1-or-later
+[Unit]
+Description=Dependent service for percent-j specifier
+After=testsuite-28-pre.service
+
+[Service]
+Type=oneshot
+ExecStart=touch /tmp/test-specifier-j-wants
diff --git a/test/testsuite-28.units/specifier-j-wants.service b/test/testsuite-28.units/specifier-j-wants.service
new file mode 100644
index 0000000..6067ba0
--- /dev/null
+++ b/test/testsuite-28.units/specifier-j-wants.service
@@ -0,0 +1,11 @@
+# SPDX-License-Identifier: LGPL-2.1-or-later
+[Unit]
+Description=Wants with percent-j specifier
+Wants=specifier-j-depends-%j.service
+After=specifier-j-depends-%j.service
+After=testsuite-28-pre.service
+
+[Service]
+Type=oneshot
+ExecStart=test -f /tmp/test-specifier-j-%j
+ExecStart=sh -c 'echo OK >/testok'
diff --git a/test/testsuite-28.units/testsuite-28-pre.service b/test/testsuite-28.units/testsuite-28-pre.service
new file mode 100644
index 0000000..0d77247
--- /dev/null
+++ b/test/testsuite-28.units/testsuite-28-pre.service
@@ -0,0 +1,4 @@
+# SPDX-License-Identifier: LGPL-2.1-or-later
+[Service]
+ExecStart=rm -f /failed /testok
+Type=oneshot