summaryrefslogtreecommitdiff
path: root/test/test-execute
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2017-09-11 19:10:06 +0200
committerLennart Poettering <lennart@poettering.net>2017-09-14 15:17:40 +0200
commit42cc99d5ec0197ea05d8da05e0457585e5106419 (patch)
tree846cdae16863d96e6c89fa8a78b8e0f93be357c4 /test/test-execute
parent00819cc15124addfa2c0d8a5d13ad3eebd009d60 (diff)
downloadsystemd-42cc99d5ec0197ea05d8da05e0457585e5106419.tar.gz
test: add test case for UnsetEnvironment=
Diffstat (limited to 'test/test-execute')
-rw-r--r--test/test-execute/exec-unset-environment.service8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/test-execute/exec-unset-environment.service b/test/test-execute/exec-unset-environment.service
new file mode 100644
index 0000000000..5b0123b81e
--- /dev/null
+++ b/test/test-execute/exec-unset-environment.service
@@ -0,0 +1,8 @@
+[Unit]
+Description=Test for UnsetEnvironment
+
+[Service]
+ExecStart=/bin/sh -x -c 'test "$$FOO" = "bar" && test "$${QUUX-X}" = "X" && test "$$VAR3" = "value3" && test "$${VAR4-X}" = "X" && test "$$VAR5" = "value5" && test "$${X%b-X}" = "X"'
+Type=oneshot
+Environment=FOO=bar QUUX=waldo VAR3=value3 VAR4=value4 VAR5=value5 X%b=%U
+UnsetEnvironment=QUUX=waldo VAR3=somethingelse VAR4 X%b=%U