Skip to content

Commit 1149913

Browse files
committed
cvdr host create E2E check multiple host creation
1 parent 15ed65e commit 1149913

1 file changed

Lines changed: 11 additions & 2 deletions

File tree

e2etests/cvdr/cvdr_host_create_test.sh

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,14 @@ set -e -x
44
source ${TEST_SRCDIR}/_main/cvdr/common_utils.sh
55
validate_components
66

7-
HOSTNAME=$(cvdr host create)
8-
cvdr host delete ${HOSTNAME}
7+
cleanup() {
8+
cvdr host delete ${HOSTNAME[@]}
9+
}
10+
trap cleanup EXIT ERR
11+
for i in $(seq 0 1); do
12+
HOSTNAME[i]=$(cvdr host create)
13+
if [[ ! $(cvdr host list) =~ ${HOSTNAME[i]} ]]; then
14+
echo "Host ${HOSTNAME[i]} doesn't exist"
15+
exit 1
16+
fi
17+
done

0 commit comments

Comments
 (0)