summaryrefslogtreecommitdiff
path: root/automated/linux
diff options
context:
space:
mode:
authorChase Qi <chase.qi@linaro.org>2016-11-23 19:56:40 +0800
committerMilosz Wasilewski <milosz.wasilewski@linaro.org>2016-11-23 12:49:39 +0000
commitfd99a37c2799106d74c657902a59c1567a608c1f (patch)
tree196024026ac62529b09f7a805590208efb59353d /automated/linux
parent3250835f73ee8494bc08ac558959d948f2a5ad25 (diff)
automated: linux: fix disk partitioning test
Change-Id: I407b65bc0d1d6e388dbe91725e7d9407d90a8823 Signed-off-by: Chase Qi <chase.qi@linaro.org>
Diffstat (limited to 'automated/linux')
-rwxr-xr-xautomated/linux/disk/disk-partitioning.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/automated/linux/disk/disk-partitioning.sh b/automated/linux/disk/disk-partitioning.sh
index 6f5d204..92b7934 100755
--- a/automated/linux/disk/disk-partitioning.sh
+++ b/automated/linux/disk/disk-partitioning.sh
@@ -1,8 +1,10 @@
#!/bin/sh
+# shellcheck disable=SC1091
. ../../lib/sh-test-lib
OUTPUT="$(pwd)/output"
RESULT_FILE="${OUTPUT}/result.txt"
+export RESULT_FILE
DISKLABEL="gpt"
FILESYSTEM="ext4"
@@ -75,7 +77,7 @@ disk_mount() {
}
# Test run.
-[ -b "${DEVICE}" ] && error_msg "Please specify a block device with '-d'"
+[ -b "${DEVICE}" ] || error_msg "Please specify a block device with '-d'"
! check_root && error_msg "You need to be root to run this script."
[ -d "${OUTPUT}" ] && mv "${OUTPUT}" "${OUTPUT}_$(date +%Y%m%d%H%M%S)"
mkdir -p "${OUTPUT}"