DockerCLI/e2e/cli-plugins
Ian Campbell 0b794e0620 e2e/cli-plugins: explicitly check that PersistentPreRunE works
I regressed this in d4ced2ef77 ("allow plugins to have argument which match a
top-level flag.") by unconditionally overwriting any `PersistentRunE` that the
user may have supplied.

We need to ensure two things:

1. That the user can use `PersistentRunE` (or `PersistentRun`) for their own
   purposes.
2. That our initialisation always runs, even if the user has used
   `PersistentRun*`, since that will shadow the root.

To do this add a `PersistentRunE` to the helloworld plugin which logs (covers 1
above) and then use it when calling the `apiversion` subcommand (which covers 2
since that uses the client)

Signed-off-by: Ian Campbell <ijc@docker.com>
2019-03-14 14:20:19 +00:00
..
plugins/badmeta Add some simple e2e tests for executing CLI plugins 2019-01-30 13:44:05 +00:00
testdata e2e/cli-plugins: explicitly check that PersistentPreRunE works 2019-03-14 14:20:19 +00:00
config_test.go Simplify cli plugin config file entry 2019-02-25 10:38:48 +00:00
dial_test.go connhelper: export functions for other projects 2019-03-02 21:11:49 +09:00
flags_test.go Add e2e test for handling of `version`/`-v`/`--version` with plugins 2019-03-13 11:28:17 +00:00
help_test.go Show plugins as Management commands 2019-02-26 00:28:41 +01:00
run_test.go e2e/cli-plugins: explicitly check that PersistentPreRunE works 2019-03-14 14:20:19 +00:00
util_test.go Simplify cli plugin config file entry 2019-02-25 10:38:48 +00:00