Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/critest: fix empty ginkgo flag's value issue
In commit 53ad8bb[1], the ginkgo uses flags.StringVar for some flags, for instance, the --skip or --focus. But in the following release of ginkgo(>=v1.15.0[2]), the ginkgo starts to use string slice instead of the StringVar, which means we can't get the user's input by the flags.Value.String()[3]. The String() always returns empty value. Based on that, we should use ginkgo API to generate flags instead of manually handler in cri-test. Reference: [1]: https://github.com/kubernetes-sigs/cri-tools/blob/53ad8bb7f97e1b1d1c0c0634e43a3c2b8b07b718/vendor/github.com/onsi/ginkgo/config/config.go L79 [2]: https://github.com/onsi/ginkgo/blob/v1.15.0/config/config.go L84 [3]: https://github.com/onsi/ginkgo/blob/v1.15.0/config/config.go L68-L71 Signed-off-by: Wei Fu <fuweid89@gmail.com>
- Loading branch information