[lxc-devel] [lxd/master] tests: Fix shellcheck being confused by cd

stgraber on Github lxc-bot at linuxcontainers.org
Wed Dec 21 08:28:01 UTC 2016


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 354 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20161221/07ff78c2/attachment.bin>
-------------- next part --------------
From 52b07f0b1ddaf296e820ba7ad4c49a06445c687e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Wed, 21 Dec 2016 03:26:54 -0500
Subject: [PATCH] tests: Fix shellcheck being confused by cd
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
 test/suites/filemanip.sh | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/test/suites/filemanip.sh b/test/suites/filemanip.sh
index 9f970e3..ab7ade6 100644
--- a/test/suites/filemanip.sh
+++ b/test/suites/filemanip.sh
@@ -1,6 +1,8 @@
 #!/bin/sh
 
 test_filemanip() {
+  # Workaround for shellcheck getting confused by "cd"
+  set -e
   ensure_import_testimage
   ensure_has_localhost_remote "${LXD_ADDR}"
 


More information about the lxc-devel mailing list