File tree 3 files changed +21
-4
lines changed
3 files changed +21
-4
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,11 @@ if command -v gfind > /dev/null 2>&1; then
11
11
FIND=" $( which gfind) "
12
12
fi
13
13
14
+ DOCKER_COMPOSE=" docker-compose"
15
+ if docker --help | grep -q -F ' compose*' ; then
16
+ DOCKER_COMPOSE=" docker compose"
17
+ fi
18
+
14
19
run_test () {
15
20
local exit_code
16
21
echo
@@ -20,10 +25,10 @@ run_test() {
20
25
(
21
26
cd " $1 "
22
27
set +e
23
- docker-compose up --build --abort-on-container-exit --exit-code-from tests
28
+ $DOCKER_COMPOSE up --build --abort-on-container-exit --exit-code-from tests
24
29
exit_code=" $? "
25
30
26
- docker-compose down -v
31
+ $DOCKER_COMPOSE down -v
27
32
if [[ " $exit_code " != 0 ]]; then
28
33
exit " $exit_code "
29
34
fi
Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
2
cd $( dirname $0 )
3
- docker-compose up
3
+
4
+ DOCKER_COMPOSE=" docker-compose"
5
+ if docker --help | grep -q -F ' compose*' ; then
6
+ DOCKER_COMPOSE=" docker compose"
7
+ fi
8
+
9
+ $DOCKER_COMPOSE up
Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
2
cd unit-tests
3
- docker-compose up --build --abort-on-container-exit --exit-code-from tests
3
+
4
+ DOCKER_COMPOSE=" docker-compose"
5
+ if docker --help | grep -q -F ' compose*' ; then
6
+ DOCKER_COMPOSE=" docker compose"
7
+ fi
8
+
9
+ $DOCKER_COMPOSE up --build --abort-on-container-exit --exit-code-from tests
You can’t perform that action at this time.
0 commit comments