Skip to content

Commit

Permalink
CASMHMS-6294: Fix docker-compose invocations
Browse files Browse the repository at this point in the history
  • Loading branch information
jwlv committed Dec 8, 2024
1 parent 0bd5723 commit 5b6dc09
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
14 changes: 7 additions & 7 deletions runCT.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
# MIT License
#
# (C) Copyright [2022] Hewlett Packard Enterprise Development LP
# (C) Copyright [2022,2024] Hewlett Packard Enterprise Development LP
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
Expand Down Expand Up @@ -34,7 +34,7 @@ echo "COMPOSE_FILE: $COMPOSE_FILE"

function cleanup() {
echo "Cleaning up containers..."
docker-compose down
docker compose down
if ! [[ $? -eq 0 ]]; then
echo "Failed to decompose environment!"
exit 1
Expand All @@ -44,16 +44,16 @@ function cleanup() {

# Get the base containers running
echo "Starting containers..."
docker-compose build --no-cache
docker-compose up --exit-code-from wait-for-smd wait-for-smd
docker-compose up --exit-code-from smoke-tests smoke-tests
docker compose build --no-cache
docker compose up --exit-code-from wait-for-smd wait-for-smd
docker compose up --exit-code-from smoke-tests smoke-tests
test_result=$?
if [[ $test_result -ne 0 ]]; then
echo "CT smoke tests FAILED!"
cleanup 1
fi

docker-compose up --exit-code-from tavern-tests tavern-tests
docker compose up --exit-code-from tavern-tests tavern-tests
test_result=$?
if [[ $test_result -ne 0 ]]; then
echo "CT tavern tests FAILED!"
Expand All @@ -62,4 +62,4 @@ fi

# Cleanup
echo "CT tests PASSED!"
cleanup 0
cleanup 0
8 changes: 4 additions & 4 deletions runUnitTest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# MIT License
#
# (C) Copyright [2021-2022] Hewlett Packard Enterprise Development LP
# (C) Copyright [2021-2022,2024] Hewlett Packard Enterprise Development LP
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the "Software"),
Expand Down Expand Up @@ -33,7 +33,7 @@ echo "COMPOSE_FILE: $COMPOSE_FILE"


function cleanup() {
docker-compose down
docker compose down
if ! [[ $? -eq 0 ]]; then
echo "Failed to decompose environment!"
exit 1
Expand All @@ -43,8 +43,8 @@ function cleanup() {


echo "Starting containers..."
docker-compose build --no-cache
docker-compose up --exit-code-from unit-tests unit-tests
docker compose build --no-cache
docker compose up --exit-code-from unit-tests unit-tests

test_result=$?

Expand Down

0 comments on commit 5b6dc09

Please sign in to comment.