commit | 4de93e11dbacb5825b8b9592a1970e79c4367e89 | [log] [tgz] |
---|---|---|
author | Marcel van Lohuizen <mpvl@golang.org> | Tue Jul 02 20:04:10 2019 +0200 |
committer | Marcel van Lohuizen <mpvl@golang.org> | Wed Jul 03 11:44:56 2019 +0000 |
tree | f53f0b2f6e2fb09532ad8dfe6b306a5fb8a97797 | |
parent | 865f1595764cbdaecfa81f6436917bf05deec89d [diff] [blame] |
encoding/openapi: add Info and DescriptorFunc features Two settings added to Generator: - Info adds the OpenAPI info section. - DescriptorFunc allows for custom descriptions, given a value. If the All API is used, an empty info section will be added if the user hasn't given any. This is to reflect the fact that info.version and info.title are required. Issue #56 Change-Id: Ief29b40bf6be9c8026052588f6de9fb06d41095f Reviewed-on: https://cue-review.googlesource.com/c/cue/+/2442 Reviewed-by: Marcel van Lohuizen <mpvl@golang.org>
diff --git a/encoding/openapi/testdata/openapi.json b/encoding/openapi/testdata/openapi.json index c0ef7db..d4c6691 100644 --- a/encoding/openapi/testdata/openapi.json +++ b/encoding/openapi/testdata/openapi.json
@@ -1,5 +1,6 @@ { "openapi": "3.0.0", + "info": {}, "components": { "schema": { "MyMessage": {