mirror of https://github.com/golang/go.git
Govim tests expect error messages to use 'any', so build gopls using the RC. For golang/go#51056 Change-Id: I0f8cab5d7eea3efbbd5b3f3dd9918e85831c2d50 Reviewed-on: https://go-review.googlesource.com/c/tools/+/388436 Trust: Robert Findley <rfindley@google.com> Run-TryBot: Robert Findley <rfindley@google.com> gopls-CI: kokoro <noreply+kokoro@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Jamal Carvalho <jamal@golang.org> |
||
|---|---|---|
| .. | ||
| Dockerfile | ||
| README.md | ||
| artifacts.go | ||
| cloudbuild.harness.yaml | ||
| cloudbuild.yaml | ||
| run_local.sh | ||
| run_tests_for_cloudbuild.sh | ||
README.md
govim integration tests
Files in this directory configure Cloud Build to run govim integration tests against a gopls binary built from source.
Running on GCP
To run these integration tests in Cloud Build, use the following steps. Here
we assume that $PROJECT_ID is a valid GCP project and $BUCKET is a cloud
storage bucket owned by that project.
cdto the root directory of the tools project.- (at least once per GCP project) Build the test harness:
$ gcloud builds submit \
--project="${PROJECT_ID}" \
--config=gopls/integration/govim/cloudbuild.harness.yaml
- Run the integration tests:
$ gcloud builds submit \
--project="${PROJECT_ID}" \
--config=gopls/integration/govim/cloudbuild.yaml \
--substitutions=_RESULT_BUCKET="${BUCKET}"
Fetching Artifacts
Assuming the artifacts bucket is world readable, you can fetch integration from GCS. They are located at:
- logs:
https://storage.googleapis.com/${BUCKET}/log-${EVALUATION_ID}.txt - artifact tarball:
https://storage.googleapis.com/${BUCKET}/govim/${EVALUATION_ID}/artifacts.tar.gz
The artifacts.go command can be used to fetch both artifacts using an
evaluation id.
Running locally
Run gopls/integration/govim/run_local.sh. This may take a while the first
time it is run, as it will require building the test harness. This script
accepts two flags to modify its behavior:
--sudo: run docker with sudo
--short: run go test -short