kubectl/pkg/explain
Antoine Pelisse 2c4bec21e5 openapi: Make file client more easy to re-use
A few notes about the change:
1. I need to initialize the fileclient once, in an init function, so I
don't have access to `testing.T` yet.
2. I want to be able to configure the openapi files that I use
3. We already have a "cache" client that wraps another client, we don't
need to re-implement caching here, one can just do:
`cache.NewClient(openapitest.NewFileClient("some/path"))` to do a cached
client. Or initialize it in an init/global var.

Since there is still some value to use the embedded file, make an
alternative constructor while using fs.FS interface to be able to
manipulate both virtual and disk-based filesystems.

Kubernetes-commit: 29503fd8d45bc2c9438e92936bf4111162529b40
2023-03-28 13:40:28 -07:00
..
v2 openapi: Make file client more easy to re-use 2023-03-28 13:40:28 -07:00
OWNERS Check in OWNERS modified by update-yamlfmt.sh 2021-12-09 21:31:26 -05:00
explain.go kubectl explain: detect resource group in case there are two or more groups discovered 2021-01-14 09:08:20 +01:00
explain_test.go fix(kubectl): explain crds with the same resource name with builtin objects 2020-03-26 16:07:06 +08:00
field_lookup.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
field_lookup_test.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
fields_printer.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
fields_printer_builder.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
fields_printer_test.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
formatter.go clean true judge 2021-04-27 20:11:36 +08:00
formatter_test.go Replace apimachinery diff.StringDiff with cmp 2023-03-23 11:10:32 -07:00
model_printer.go Fix printing control character in kubectl explain 2022-01-20 15:04:15 +01:00
model_printer_test.go Fix printing control character in kubectl explain 2022-01-20 15:04:15 +01:00
recursive_fields_printer.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
recursive_fields_printer_test.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
test-recursive-swagger.json Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
test-swagger.json Fix printing control character in kubectl explain 2022-01-20 15:04:15 +01:00
typename.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00
typename_test.go Move pkg/kubect/explain to staging 2019-07-29 14:57:41 -07:00