diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/basic/namespace.t | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/tests/basic/namespace.t b/tests/basic/namespace.t index 7f4fe2c9268..25a6b98b440 100644 --- a/tests/basic/namespace.t +++ b/tests/basic/namespace.t @@ -11,12 +11,14 @@ NAMESPACE2_HASH=3926991974 NAMESPACE3_HASH=3493960770 function check_brick_multiplex() { - $CLI volume info|grep "cluster.brick-multiplex" &>/dev/null - rt=$? - cnt="$(ls /var/log/glusterfs/bricks|wc -l)" + local ret=$($CLI volume info|grep "cluster.brick-multiplex"|cut -d" " -f2) + local cnt="$(ls /var/log/glusterfs/bricks|wc -l)" + local bcnt="$(brick_count)" - if [ $rt -eq 0 ]; then - local ret=$($CLI volume info|grep "cluster.brick-multiplex"|cut -d" " -f2) + if [ $bcnt -ne 1 ]; then + if [ -z $ret ]; then + ret="no" + fi if [ $ret = "on" ] || [ $cnt -eq 1 ]; then echo "Y" |