8000 tests: faster docker shutdown · python-gitlab/python-gitlab@d8db707 · GitHub
[go: up one dir, main page]

Skip to content

Commit d8db707

Browse files
author
Gauvain Pocentek
committed
tests: faster docker shutdown
Kill the test container violently, no need to wait for a proper shutdown.
1 parent 0099ff2 commit d8db707

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

tools/build_test_env.sh

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -64,18 +64,12 @@ CONFIG=/tmp/python-gitlab.cfg
6464

6565
cleanup() {
6666
rm -f "${CONFIG}"
67-
log "Stopping gitlab-test docker container..."
68-
docker stop gitlab-test >/dev/null &
69-
docker_stop_pid=$!
70-
log "Waiting for gitlab-test docker container to exit..."
71-
docker wait gitlab-test >/dev/null
72-
wait "${docker_stop_pid}"
73-
log "Removing gitlab-test docker container..."
74-
docker rm gitlab-test >/dev/null
7567
log "Deactivating Python virtualenv..."
7668
command -v deactivate >/dev/null 2>&1 && deactivate || true
7769
log "Deleting python virtualenv..."
7870
rm -rf "$VENV"
71+
log "Stopping gitlab-test docker container..."
72+
docker rm -f gitlab-test >/dev/null
7973
log "Done."
8074
}
8175
[ -z "${BUILD_TEST_ENV_AUTO_CLEANUP+set}" ] || {

0 commit comments

Comments
 (0)
0