From 70d7a63deb91edfdc48d03090e76445f3f02281e Mon Sep 17 00:00:00 2001 From: Preetha Date: Thu, 3 Jan 2019 13:24:58 -0600 Subject: [PATCH] Update e2e readme --- e2e/README.md | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) diff --git a/e2e/README.md b/e2e/README.md index d2331daf0..5f0ab6916 100644 --- a/e2e/README.md +++ b/e2e/README.md @@ -1,19 +1,22 @@ End to End Tests ================ -This package contains integration tests that are not run by default. To run them use the `-integration` flag. Example: +This package contains integration tests. + +The `terraform` folder has provisioning code to spin up a Nomad cluster on AWS. The tests work with the `NOMAD_ADDR` environment variable which can be set either to a local dev Nomad agent or a client on AWS. + +Local Development +================= +The workflow when developing end to end tests locally is to run the provisioning step described below once, and then run the tests as described below. + +Provisioning +============ +You'll need AWS credentials (`AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY`) to create the Nomad cluster. See the [README](https://github.com/hashicorp/nomad/blob/master/e2e/terraform/README.md) for details. The number of servers and clients is configurable, as is the configuration file for each client and server. + +Running +=========== +After completing the provisioning step above, you should see CLI output showing the IP addresses of Nomad client machines. To run the tests, set the NOMAD_ADDR variable to one of the client IPs. ``` -$ cd e2e/rescheduling/ -$ go test -integration -Running Suite: Server Side Restart Tests -======================================== -Random Seed: 1520633027 -Will run 7 of 7 specs - -••••••• -Ran 7 of 7 Specs in 4.231 seconds -SUCCESS! -- 7 Passed | 0 Failed | 0 Pending | 0 Skipped PASS -ok github.com/hashicorp/nomad/e2e/rescheduling 4.239s - -``` \ No newline at end of file +$ NOMAD_ADDR=<> $NOMAD_E2E=1 go test -v +```