Signed-off-by: Anthony Sottile <asottile@umich.edu>
| ... | ... |
@@ -9,7 +9,7 @@ |
| 9 | 9 |
# docker run -v `pwd`:/go/src/github.com/docker/docker --privileged -i -t docker bash |
| 10 | 10 |
# |
| 11 | 11 |
# # Run the test suite: |
| 12 |
-# docker run --privileged docker hack/make.sh test-unit test-integration-cli test-docker-py |
|
| 12 |
+# docker run --privileged docker hack/make.sh test-unit test-integration test-docker-py |
|
| 13 | 13 |
# |
| 14 | 14 |
# # Publish a release: |
| 15 | 15 |
# docker run --privileged \ |
| ... | ... |
@@ -47,7 +47,7 @@ testing: |
| 47 | 47 |
| ---------------------- | ---------------------------------------------- | |
| 48 | 48 |
| `test` | Run the unit, integration, and docker-py tests | |
| 49 | 49 |
| `test-unit` | Run just the unit tests | |
| 50 |
-| `test-integration-cli` | Run the integration tests for the CLI | |
|
| 50 |
+| `test-integration` | Run the integration tests | |
|
| 51 | 51 |
| `test-docker-py` | Run the tests for the Docker API client | |
| 52 | 52 |
|
| 53 | 53 |
Running the entire test suite on your current repository can take over half an |
| ... | ... |
@@ -113,7 +113,7 @@ Try this now. |
| 113 | 113 |
3. Run the tests using the `hack/make.sh` script. |
| 114 | 114 |
|
| 115 | 115 |
```bash |
| 116 |
- root@5f8630b873fe:/go/src/github.com/moby/moby# hack/make.sh dynbinary binary cross test-unit test-integration-cli test-docker-py |
|
| 116 |
+ root@5f8630b873fe:/go/src/github.com/moby/moby# hack/make.sh dynbinary binary cross test-unit test-integration test-docker-py |
|
| 117 | 117 |
``` |
| 118 | 118 |
|
| 119 | 119 |
The tests run just as they did within your local host. |
| ... | ... |
@@ -164,13 +164,13 @@ flag's value is passed as arguments to the `go test` command. For example, from |
| 164 | 164 |
your local host you can run the `TestBuild` test with this command: |
| 165 | 165 |
|
| 166 | 166 |
```bash |
| 167 |
-$ TESTFLAGS='-check.f DockerSuite.TestBuild*' make test-integration-cli |
|
| 167 |
+$ TESTFLAGS='-check.f DockerSuite.TestBuild*' make test-integration |
|
| 168 | 168 |
``` |
| 169 | 169 |
|
| 170 | 170 |
To run the same test inside your Docker development container, you do this: |
| 171 | 171 |
|
| 172 | 172 |
```bash |
| 173 |
-root@5f8630b873fe:/go/src/github.com/moby/moby# TESTFLAGS='-check.f TestBuild*' hack/make.sh binary test-integration-cli |
|
| 173 |
+root@5f8630b873fe:/go/src/github.com/moby/moby# TESTFLAGS='-check.f TestBuild*' hack/make.sh binary test-integration |
|
| 174 | 174 |
``` |
| 175 | 175 |
|
| 176 | 176 |
## Test the Windows binary against a Linux daemon |
| ... | ... |
@@ -207,14 +207,14 @@ run a Bash terminal on Windows. |
| 207 | 207 |
5. Make the binary and run the tests: |
| 208 | 208 |
|
| 209 | 209 |
```bash |
| 210 |
- $ hack/make.sh binary test-integration-cli |
|
| 210 |
+ $ hack/make.sh binary test-integration |
|
| 211 | 211 |
``` |
| 212 | 212 |
Some tests are skipped on Windows for various reasons. You can see which |
| 213 | 213 |
tests were skipped by re-running the make and passing in the |
| 214 | 214 |
`TESTFLAGS='-test.v'` value. For example |
| 215 | 215 |
|
| 216 | 216 |
```bash |
| 217 |
- $ TESTFLAGS='-test.v' hack/make.sh binary test-integration-cli |
|
| 217 |
+ $ TESTFLAGS='-test.v' hack/make.sh binary test-integration |
|
| 218 | 218 |
``` |
| 219 | 219 |
|
| 220 | 220 |
Should you wish to run a single test such as one with the name |
| ... | ... |
@@ -222,7 +222,7 @@ run a Bash terminal on Windows. |
| 222 | 222 |
example |
| 223 | 223 |
|
| 224 | 224 |
```bash |
| 225 |
- $ TESTFLAGS='-check.f TestExample' hack/make.sh binary test-integration-cli |
|
| 225 |
+ $ TESTFLAGS='-check.f TestExample' hack/make.sh binary test-integration |
|
| 226 | 226 |
``` |
| 227 | 227 |
|
| 228 | 228 |
You can now choose to make changes to the Moby source or the tests. If you |
| ... | ... |
@@ -12,7 +12,7 @@ IT on Swarm allows you to execute integration test in parallel across a Docker S |
| 12 | 12 |
### Worker service |
| 13 | 13 |
|
| 14 | 14 |
- Works as a funker callee |
| 15 |
- - Executes an equivalent of `TESTFLAGS=-check.f TestFoo|TestBar|TestBaz ... make test-integration-cli` using the bind-mounted API socket (`docker.sock`) |
|
| 15 |
+ - Executes an equivalent of `TESTFLAGS=-check.f TestFoo|TestBar|TestBaz ... make test-integration` using the bind-mounted API socket (`docker.sock`) |
|
| 16 | 16 |
|
| 17 | 17 |
### Client |
| 18 | 18 |
|
| ... | ... |
@@ -43,7 +43,7 @@ func privilegedTestChunkExecutor(autoRemove bool) testChunkExecutor {
|
| 43 | 43 |
} |
| 44 | 44 |
graphdriver = info.Driver |
| 45 | 45 |
} |
| 46 |
- // `daemon_dest` is similar to `$DEST` (e.g. `bundles/VERSION/test-integration-cli`) |
|
| 46 |
+ // `daemon_dest` is similar to `$DEST` (e.g. `bundles/VERSION/test-integration`) |
|
| 47 | 47 |
// but it exists outside of `bundles` so as to make `$DOCKER_GRAPHDRIVER` work. |
| 48 | 48 |
// |
| 49 | 49 |
// Without this hack, `$DOCKER_GRAPHDRIVER` fails because of (e.g.) `overlay2 is not supported over overlayfs` |
| ... | ... |
@@ -65,7 +65,7 @@ func privilegedTestChunkExecutor(autoRemove bool) testChunkExecutor {
|
| 65 | 65 |
"org.dockerproject.integration-cli-on-swarm.comment": "this non-service container is created for running privileged programs on Swarm. you can remove this container manually if the corresponding service is already stopped.", |
| 66 | 66 |
}, |
| 67 | 67 |
Entrypoint: []string{"hack/dind"},
|
| 68 |
- Cmd: []string{"hack/make.sh", "test-integration-cli"},
|
|
| 68 |
+ Cmd: []string{"hack/make.sh", "test-integration"},
|
|
| 69 | 69 |
} |
| 70 | 70 |
hostConfig := container.HostConfig{
|
| 71 | 71 |
AutoRemove: autoRemove, |
| ... | ... |
@@ -26,7 +26,7 @@ func enumerateTestsForBytes(b []byte) ([]string, error) {
|
| 26 | 26 |
|
| 27 | 27 |
// enumerateTests enumerates valid `-check.f` strings for all the test functions. |
| 28 | 28 |
// Note that we use regexp rather than parsing Go files for performance reason. |
| 29 |
-// (Try `TESTFLAGS=-check.list make test-integration-cli` to see the slowness of parsing) |
|
| 29 |
+// (Try `TESTFLAGS=-check.list make test-integration` to see the slowness of parsing) |
|
| 30 | 30 |
// The files needs to be `gofmt`-ed |
| 31 | 31 |
// |
| 32 | 32 |
// The result will be as follows, but unsorted ('$' is appended because they are regexp for `-check.f`):
|