Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
prowjobs Move Daisy test runner to /daisy module so that latest Daisy is alway… Feb 6, 2020

GoogleCloudPlatform/compute-image-tools testing infrastructure

Prow and Gubenator

We use Prow to run periodic, postsubmit, and presubmit (PRs) tests on packages in this. repo. Our Prow GKE cluster runs in the GCP project, compute-image-tools-test.

We publish test results to Gubenator. Specifically, we publish test data/logs to the publicly readable GCS bucket, compute-image-tools-test.


Layout of test-infra/

Path Description
prow/ Configuration for the Prow cluster.
prow/config.yaml Configuration describing Prow events and the associated Prow job containers.
prow/plugins.yaml Configuration for Prow plugins.
prowjobs/ Prow job containers.
prowjobs/daisy-e2e/ Runs workflows in daisy_workflows against the latest (master:HEAD) Daisy binary.
prowjobs/gce-image-import-export-tests/ Runs image importer/exporter tests against the latest (master:HEAD) Image Importer/Exporter binary.
prowjobs/gce-ovf-import-tests/ Runs OVF importer tests against the latest (master:HEAD) OVF Importer binary.
prowjobs/gocheck/ Runs go fmt, golint, go vet against Go code in the repo.
prowjobs/osconfig-tests/ Runs OS Config tests.
prowjobs/flake8/ Runs flake8 against python code in the repo.
prowjobs/unittests/ Runs all scripts within the repo with the filename Each script is run within its own directory. Publishes code coverage results to Codecov.
prowjobs/wrapper/ Imported by other Prow jobs. Contains a wrapper binary that manages test log/artifact uploads.

Prow job wrapper binary

The container in prowjobs/wrapper/ is not a Prow job itself. It contains a binary which is imported by other other Prow job containers at container build time.

The wrapper binary is wraps the container entry point. It handles logging to the GCS bucket we use for Gubenator. The wrapper logs start, finish, and build logs. It also uploads all artifacts found in the artifacts directory. The artifacts directory is set with the environment variable ${ARTIFACTS}.

Prow job: test-runner

test-runner runs the latest daisy_test_runner binary against the test template.

Prow job: daisy-e2e

daisy-e2e invokes our latest Daisy binary against the compute-image-tools-test GCP project. It runs the workflows matching daisy_worklows/e2e_tests/*.wf.json. Each matching workflow is run as a test case.

Prow job: gce-image-import-export-tests

gce-image-import-export-tests invokes our latest Image Importer/Exporter binary against the compute-image-tools-test GCP project. It runs the tests defined in gce_image_import_export_tests.

Prow job: gce-ovf-import-tests

gce-ovf-import-tests invokes our latest OVF Importer binary against the compute-image-tools-test GCP project. It runs the tests defined in gce_ovf_import_tests.

Periodic runs and testgrid

This job is run periodically and results are uploaded to Gubenator and testgrid. Testgrid is managed by the Kubernetes. Configuration changes require a pull request. See for an example.

Prow job: gocheck

Runs go fmt, go vet, and golint, checking for proper Go style and formatting of ALL Go code within the repo.

Prow job: flake8

Runs flake8 checking for proper python style of ALL python code within the repo.

Prow job: unittests

The unittests Prow job runs all scripts with the name in the repo. It is up to each script to run the unit tests for the code its testing. The script returns a nonzero status to indicate test failures.

Test artifacts

Artifacts, such as unit test reports, produced by a script should be published in a directory, artifacts, in the same directory as the script. After a script terminates, artifacts are moved from its own artifacts directory to a subdirectory of /artifacts in preparation to be uploaded by the wrapper.

Coverage reports

Two environment variables, ${GOCOVPATH} and ${PYCOVPATH}, are available to the scripts. These are paths to Go and Python code coverage reports which will be uploaded to codecov. Code coverage output must be APPENDED to these filepaths.

You can’t perform that action at this time.