summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2021-04-08 10:34:28 +0200
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2021-05-06 13:58:15 +0200
commite976b34e3b0bc2e0c3f612e7b82b8af2a45147d9 (patch)
tree96df771d98442167134274f51888d61489a59259 /test
parent31d4c69bd2c3ed35e73213a6994fcdda76b61156 (diff)
downloadsystemd-e976b34e3b0bc2e0c3f612e7b82b8af2a45147d9.tar.gz
homectl,TEST-46: fix test and fix homectl return value, update docs
The usual: the test wasn't testing, so we didn't notice that the command wasn't returning as expected. (cherry picked from commit b9bfa250f2c04caeecd49e54cdbadee3986d64b3)
Diffstat (limited to 'test')
-rwxr-xr-xtest/units/testsuite-46.sh8
1 files changed, 6 insertions, 2 deletions
diff --git a/test/units/testsuite-46.sh b/test/units/testsuite-46.sh
index 00bbdf507e..55f526d2ab 100755
--- a/test/units/testsuite-46.sh
+++ b/test/units/testsuite-46.sh
@@ -66,11 +66,15 @@ inspect test-user
PASSWORD=xEhErW0ndafV4s homectl deactivate test-user
inspect test-user
-! PASSWORD=xEhErW0ndafV4s homectl with test-user -- test -f /home/test-user/xyz
+PASSWORD=xEhErW0ndafV4s homectl with test-user -- test ! -f /home/test-user/xyz
+PASSWORD=xEhErW0ndafV4s homectl with test-user -- test -f /home/test-user/xyz \
+ && { echo 'unexpected success'; exit 1; }
PASSWORD=xEhErW0ndafV4s homectl with test-user -- touch /home/test-user/xyz
PASSWORD=xEhErW0ndafV4s homectl with test-user -- test -f /home/test-user/xyz
PASSWORD=xEhErW0ndafV4s homectl with test-user -- rm /home/test-user/xyz
-! PASSWORD=xEhErW0ndafV4s homectl with test-user -- test -f /home/test-user/xyz
+PASSWORD=xEhErW0ndafV4s homectl with test-user -- test ! -f /home/test-user/xyz
+PASSWORD=xEhErW0ndafV4s homectl with test-user -- test -f /home/test-user/xyz \
+ && { echo 'unexpected success'; exit 1; }
homectl remove test-user