Skip to content

Commit 957bee4

Browse files
committed
Add script to run tests in all docker images
1 parent fb69847 commit 957bee4

File tree

13 files changed

+88
-4
lines changed

13 files changed

+88
-4
lines changed

tests/dockerfiles/php56/2_start.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Run image to create container.
2+
3+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
set -x
5+
cd "${SCRIPT_DIR}/../../.."
6+
project_dir="${PWD}"
7+
8+
docker start "php56" ||
9+
docker run \
10+
--detach \
11+
--interactive \
12+
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
13+
--name="php56" \
14+
--tty \
15+
"php-curl-class/php56"

tests/dockerfiles/php56/4_stop.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Stop container.
2+
3+
docker stop "php56"

tests/dockerfiles/php56/2_run.sh renamed to tests/dockerfiles/php56/run_interactive.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ project_dir="${PWD}"
88
docker run \
99
--interactive \
1010
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
11-
--name=php56 \
11+
--name="php56" \
1212
--rm \
1313
--tty \
1414
"php-curl-class/php56" /bin/bash

tests/dockerfiles/php70/2_start.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Run image to create container.
2+
3+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
set -x
5+
cd "${SCRIPT_DIR}/../../.."
6+
project_dir="${PWD}"
7+
8+
docker start "php70" ||
9+
docker run \
10+
--detach \
11+
--interactive \
12+
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
13+
--name="php70" \
14+
--tty \
15+
"php-curl-class/php70"

tests/dockerfiles/php70/4_stop.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Stop container.
2+
3+
docker stop "php70"

tests/dockerfiles/php70/2_run.sh renamed to tests/dockerfiles/php70/run_interactive.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ project_dir="${PWD}"
88
docker run \
99
--interactive \
1010
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
11-
--name=php70 \
11+
--name="php70" \
1212
--rm \
1313
--tty \
1414
"php-curl-class/php70" /bin/bash

tests/dockerfiles/php71/2_start.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Run image to create container.
2+
3+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
set -x
5+
cd "${SCRIPT_DIR}/../../.."
6+
project_dir="${PWD}"
7+
8+
docker start "php71" ||
9+
docker run \
10+
--detach \
11+
--interactive \
12+
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
13+
--name="php71" \
14+
--tty \
15+
"php-curl-class/php71"

tests/dockerfiles/php71/4_stop.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Stop container.
2+
3+
docker stop "php71"

tests/dockerfiles/php71/2_run.sh renamed to tests/dockerfiles/php71/run_interactive.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ project_dir="${PWD}"
88
docker run \
99
--interactive \
1010
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
11-
--name=php71 \
11+
--name="php71" \
1212
--rm \
1313
--tty \
1414
"php-curl-class/php71" /bin/bash

tests/dockerfiles/php72/2_start.sh

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Run image to create container.
2+
3+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
4+
set -x
5+
cd "${SCRIPT_DIR}/../../.."
6+
project_dir="${PWD}"
7+
8+
docker start "php72" ||
9+
docker run \
10+
--detach \
11+
--interactive \
12+
--mount "type=bind,src=${project_dir},dst=/data,readonly=true" \
13+
--name="php72" \
14+
--tty \
15+
"php-curl-class/php72"

0 commit comments

Comments
 (0)