ESP runs the presubmit unit/integration/e2e tests on Jenkins. The local tests pass may not necessarily make ESP presubmit pass as different environment. The most common reasons is some dependency incompatibility.
The address of docker image used to run presubmit is is located in Jenkinsfile under var SLAVE_IMAGE
, like
SLAVE_IMAGE = 'gcr.io/endpoints-jenkins/debian-9:0.13'
Pull the image from registry
gcloud docker -- pull ${SLAVE_IMAGE}
Run the docker image with attaching your local esp
repo path
docker container run -v ${LOCAL_ESP_REPO_PATH}:/home/esp \
-it ${SLAVE_IMAGE} /bin/bash
After sshing inside the container, reproduce the failed test target found in the test jobs, like
cd /hom/esp
bazel test start_esp/test/...
- Jenkinsfile: the central place to config all the presubmit tests
- script/presubmits: the entry of presubmit tests
- jenkins/slaves/debian-9.Dockerfile: the dockerfile of presubmit image
- script/linux-install-software: the script of installing related dependencies of presubmit image