diff --git a/test/suites/clustering_move.sh b/test/suites/clustering_move.sh index 80a70b53d30f..3ac88099ff8e 100644 --- a/test/suites/clustering_move.sh +++ b/test/suites/clustering_move.sh @@ -52,8 +52,12 @@ test_clustering_move() { LXD_DIR="${LXD_ONE_DIR}" lxc info c1 | grep -q "Location: node1" # c1 can be moved within the same cluster group if it has multiple members + current_location="$(LXD_DIR="${LXD_ONE_DIR}" lxc query /1.0/instances/c1 | jq -r '.location')" LXD_DIR="${LXD_ONE_DIR}" lxc move c1 --target=@default + LXD_DIR="${LXD_ONE_DIR}" lxc query /1.0/instances/c1 | jq -re ".location != \"$current_location\"" + current_location="$(LXD_DIR="${LXD_ONE_DIR}" lxc query /1.0/instances/c1 | jq -r '.location')" LXD_DIR="${LXD_ONE_DIR}" lxc move c1 --target=@default + LXD_DIR="${LXD_ONE_DIR}" lxc query /1.0/instances/c1 | jq -re ".location != \"$current_location\"" # c1 cannot be moved within the same cluster group if it has a single member LXD_DIR="${LXD_ONE_DIR}" lxc move c1 --target=@foobar3