Add parameter to change backend test timeout

This commit is contained in:
VDimir
2019-10-19 12:48:49 +03:00
parent a310e222d9
commit 13bdf8358a
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -20,6 +20,7 @@ ARG DRONE_BRANCH
ARG DRONE_PULL_REQUEST
ARG SKIP_BACKEND_TEST
ARG BACKEND_TEST_TIMEOUT
ADD backend /build/backend
ADD .git /build/.git
@@ -31,7 +32,7 @@ ENV GOFLAGS="-mod=vendor"
RUN \
cd app && \
if [ -z "$SKIP_BACKEND_TEST" ] ; then \
go test -p 1 -timeout=30s -covermode=count -coverprofile=/profile.cov_tmp ./... && \
go test -p 1 -timeout="${BACKEND_TEST_TIMEOUT:-30s}" -covermode=count -coverprofile=/profile.cov_tmp ./... && \
cat /profile.cov_tmp | grep -v "_mock.go" > /profile.cov ; \
else echo "skip backend test" ; fi
+1
View File
@@ -18,6 +18,7 @@ services:
dockerfile: Dockerfile
args:
- SKIP_BACKEND_TEST
- BACKEND_TEST_TIMEOUT
- SKIP_FRONTEND_TEST=true
image: umputun/remark42:dev