test/iscsi: use run_test semantics in filesystem test.

Change-Id: Ie58dfb5e6147437d325439fca9bbcaebbb4ccebb
Signed-off-by: Seth Howell <seth.howell@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/476946
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
Reviewed-by: Karol Latecki <karol.latecki@intel.com>
This commit is contained in:
Seth Howell 2019-12-05 12:53:59 -07:00 committed by Tomasz Zawadzki
parent 3e1393a795
commit 9f9f120cac

View File

@ -75,7 +75,8 @@ parted -s /dev/$dev mklabel msdos
parted -s /dev/$dev mkpart primary '0%' '100%'
sleep 1
for fstype in "ext4" "btrfs" "xfs"; do
function filesystem_test {
fstype=$1
if [ "$fstype" == "ext4" ]; then
mkfs.${fstype} -F /dev/${dev}1
@ -132,7 +133,11 @@ for fstype in "ext4" "btrfs" "xfs"; do
rm -rf /mnt/device/aaa
umount /mnt/device
fi
done
}
run_test "iscsi_tgt_filesystem_ext4" filesystem_test "ext4"
run_test "iscsi_tgt_filesystem_btrfs" filesystem_test "btrfs"
run_test "iscsi_tgt_filesystem_xfs" filesystem_test "xfs"
rm -rf /mnt/device