(core) run test:docker target prior to pushing grist-core image

Summary:
This activates the new tests that can run on a grist-core image,
and will not push a new version to `latest` tag unless those tests
pass.

This also runs a smoke test in the regular CI tests, to confirm the
code continues to work without GRIST_TEST_LOGIN enabled.

Test Plan: tested on a fork of grist-core

Reviewers: georgegevoian

Reviewed By: georgegevoian

Differential Revision: https://phab.getgrist.com/D3186
This commit is contained in:
Paul Fitzpatrick
2021-12-13 13:35:00 -05:00
parent 1ae586cf42
commit 65ac8aaa85
3 changed files with 37 additions and 3 deletions

View File

@@ -19,12 +19,13 @@ DOCKER_CONTAINER=grist-core-test
DOCKER_PID=""
cleanup() {
return_value=$?
docker rm -f $DOCKER_CONTAINER
if [ -n "$DOCKER_PID" ]; then
wait $DOCKER_PID || echo "docker container gone"
fi
echo "Cleaned up docker container, bye."
exit 0
exit $return_value
}
docker run --name $DOCKER_CONTAINER --rm \
@@ -33,7 +34,7 @@ docker run --name $DOCKER_CONTAINER --rm \
--env GRIST_SESSION_COOKIE=grist_test_cookie \
--env GRIST_TEST_LOGIN=1 \
--env TEST_SUPPORT_API_KEY=api_key_for_support \
gristlabs/grist &
${TEST_IMAGE:-gristlabs/grist} &
DOCKER_PID="$!"