This page contains information on how to develop and test the driver locally.
$ export PROJECT=my-project # GCP Project to run tests in
$ export GCE_PD_SA_NAME=$PROJECT-pd-sa # Name of the service account to create
$ export GCE_PD_SA_DIR=/my/safe/credentials/directory # Directory to save the service account key
$ export ENABLE_KMS=false
$ ./deploy/setup-project.sh
$ export PROJECT=my-project # GCP Project to run tests in
$ export GCE_PD_SA_NAME=$PROJECT-pd-sa
$ export IAM_NAME=$GCE_PD_SA_NAME@$PROJECT.iam.gserviceaccount.com # IAM SA that was set up in "one time setup"
$ ./test/run-e2e-local.sh
NOTE: Sanity tests are currently failing, tracked by go/pdcsi-oss-driver/issues/990.
Sanity tests can be run from VS Code, etc directly or via the cmd line:
$ ./test/run-sanity.sh
Unit tests can be run from VS Code, etc directly or via the cmd line:
$ ./test/run-unit.sh
Use dep
$ dep ensure
To modify dependencies or versions change ./Gopkg.toml