summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2014-06-28 12:23:45 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2014-06-28 12:23:45 -0400
commit2ab71dc62a85985e76bbf8b94838cdd4d6105128 (patch)
treedbbe5d6ba080b06c4245e2e736a855080fc28032
parentfa10f46235a57a8f2084578c001f6293e58bce49 (diff)
test/librechroot: work-around for a systemd bug
-rw-r--r--test/librechroot-test.sh10
1 files changed, 9 insertions, 1 deletions
diff --git a/test/librechroot-test.sh b/test/librechroot-test.sh
index 43f3143..c3026da 100644
--- a/test/librechroot-test.sh
+++ b/test/librechroot-test.sh
@@ -41,7 +41,15 @@ it_respects_exit_status_if_out_isnt_a_tty() (
libremessages msg 'Creating a chroot, may take a few minutes' &>/dev/tty
r=0
{ testsudo librechroot -l "$roundup_test_name" run bash -c 'exit 3' | cat; } || r=$?
- [[ $r == 3 ]]
+
+ # Work around http://lists.freedesktop.org/archives/systemd-devel/2014-June/020685.html
+ # Hopefully the fix gets merged for 215
+ systemd_ver=$(systemd-nspawn --version|sed -n 's|^systemd ||p')
+ if [[ $systemd_ver =~ 213|214 ]]; then
+ [[ $r == 1 ]]
+ else
+ [[ $r == 3 ]]
+ fi
)
it_creates_ca_certificates() {