diff --git a/tests/go/Dockerfile b/tests/go/Dockerfile index 4bed8627..fbf09685 100644 --- a/tests/go/Dockerfile +++ b/tests/go/Dockerfile @@ -1,7 +1,8 @@ -FROM golang:1 +FROM golang:1-alpine +RUN apk add git RUN go get golang.org/x/tools/cmd/goimports RUN go get github.com/01-edu/z01 RUN go get github.com/01-edu/public/rc COPY . /app -ENTRYPOINT ["/bin/bash", "/app/entrypoint.sh"] +ENTRYPOINT ["/bin/sh", "/app/entrypoint.sh"] diff --git a/tests/sh/Dockerfile b/tests/sh/Dockerfile index ff967378..eec532b4 100644 --- a/tests/sh/Dockerfile +++ b/tests/sh/Dockerfile @@ -1,6 +1,5 @@ -FROM debian +FROM alpine -RUN apt-get update -RUN apt-get install -y jq curl git +RUN apk add jq curl git COPY . /app -ENTRYPOINT ["/bin/bash", "/app/entrypoint.sh"] +ENTRYPOINT ["/bin/sh", "/app/entrypoint.sh"] diff --git a/tests/sh/entrypoint.sh b/tests/sh/entrypoint.sh index fa090c35..1668bdfd 100755 --- a/tests/sh/entrypoint.sh +++ b/tests/sh/entrypoint.sh @@ -1,7 +1,7 @@ #!/bin/sh -# Unofficial Bash Strict Mode -set -euo pipefail +set -o errexit +set -o pipefail IFS=' ' @@ -11,5 +11,5 @@ if ! test -f ${EXERCISE}_test.sh; then echo No test file found for the exercise : "$EXERCISE" exit 1 fi -bash ${EXERCISE}_test.sh +sh ${EXERCISE}_test.sh echo PASS