README
¶
Kube OpenAPI Integration Tests
Running the integration tests
Within the current directory:
$ go test -v .
Generating the golden Swagger definition file
First, run the generator to create openapi_generated.go
file which specifies
the OpenAPIDefinition
for each type.
$ go run ../../cmd/openapi-gen/openapi-gen.go -i "./testdata/listtype" -o pkg -p generated -O openapi_generated
The generated file pkg/generated/openapi_generated.go
should have been created.
Next, run the OpenAPI builder to create the Swagger file which includes
the definitions. The output file named golden.json
will be output in
the current directory.
$ go run builder/main.go golden.json
Click to show internal directories.
Click to hide internal directories.