package testing
import "k8s.io/kubernetes/pkg/kubectl/cmd/util/openapi/testing"
Index ¶
Types ¶
type Fake ¶
type Fake struct { Path string // contains filtered or unexported fields }
Fake opens and returns a openapi swagger from a file Path. It will parse only once and then return the same copy everytime.
func (*Fake) OpenAPISchema ¶
OpenAPISchema returns the openapi document and a potential error.
type FakeClient ¶
FakeClient implements a dummy OpenAPISchemaInterface that uses the fake OpenAPI schema given as a parameter, and count the number of call to the function.
func NewFakeClient ¶
func NewFakeClient(f *Fake) *FakeClient
NewFakeClient creates a new FakeClient from the given Fake.
func (*FakeClient) OpenAPISchema ¶
func (f *FakeClient) OpenAPISchema() (*openapi_v2.Document, error)
OpenAPISchema returns a OpenAPI Document as returned by the fake, but it also counts the number of calls.
Source Files ¶
openapi.go
- Version
- v1.8.2-beta.0
- Published
- Oct 11, 2017
- Platform
- js/wasm
- Imports
- 6 packages
- Last checked
- 2 minutes ago –
Tools for package owners.