test/nvmf: fix some nvme_cli.sh test issues
1) remove unnecessary disconnect for cnode2 - this subsystem doesn't exist (and the || true was hiding the failure 2) remove || true from the cnode1 disconnect 3) remove extra spaces when assigning nvme_model - maybe these spaces are OK on some versions of bash, but when I run this locally this doesn't work at all 4) remove trailing spaces from model returned by identify data before comparison Signed-off-by: Jim Harris <james.r.harris@intel.com> Change-Id: If3dd7ddc2ba44fc880e5b398b5fe0922b6637b80 Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/454689 Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Seth Howell <seth.howell5141@gmail.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
03c309432b
commit
178b06b438
@ -45,7 +45,7 @@ nvme list
|
||||
for ctrl in /dev/nvme?; do
|
||||
nvme id-ctrl $ctrl
|
||||
nvme smart-log $ctrl
|
||||
nvme_model = $(nvme id-ctrl $ctrl | grep -w mn | sed 's/^.*: //')
|
||||
nvme_model=$(nvme id-ctrl $ctrl | grep -w mn | sed 's/^.*: //' | sed 's/ *$//')
|
||||
if [ "$nvme_model" != "SPDK_Controller1" ]; then
|
||||
echo "Wrong model number for controller" $nvme_model
|
||||
exit 1
|
||||
@ -56,8 +56,7 @@ for ns in /dev/nvme?n*; do
|
||||
nvme id-ns $ns
|
||||
done
|
||||
|
||||
nvme disconnect -n "nqn.2016-06.io.spdk:cnode1" || true
|
||||
nvme disconnect -n "nqn.2016-06.io.spdk:cnode2" || true
|
||||
nvme disconnect -n "nqn.2016-06.io.spdk:cnode1"
|
||||
|
||||
if [ -d $spdk_nvme_cli ]; then
|
||||
# Test spdk/nvme-cli NVMe-oF commands: discover, connect and disconnect
|
||||
|
Loading…
Reference in New Issue
Block a user