mirror of
https://github.com/project-zot/zot.git
synced 2024-12-30 22:34:13 -05:00
docs: improve docs coverage
Signed-off-by: Ramkumar Chinchani <rchincha@cisco.com>
This commit is contained in:
parent
d930adbd49
commit
2d9c1f52ea
2 changed files with 19 additions and 0 deletions
|
@ -733,6 +733,10 @@ var SwaggerInfo = swaggerInfo{Schemes: []string{}}
|
|||
|
||||
type s struct{}
|
||||
|
||||
func New() *s {
|
||||
return &s{}
|
||||
}
|
||||
|
||||
func (s *s) ReadDoc() string {
|
||||
t, err := template.New("swagger_info").Funcs(template.FuncMap{
|
||||
"marshal": func(v interface{}) string {
|
||||
|
|
15
docs/docs_test.go
Normal file
15
docs/docs_test.go
Normal file
|
@ -0,0 +1,15 @@
|
|||
package docs_test
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/anuvu/zot/docs"
|
||||
. "github.com/smartystreets/goconvey/convey"
|
||||
)
|
||||
|
||||
func TestDocs(t *testing.T) {
|
||||
Convey("Read docs", t, func() {
|
||||
s := docs.New()
|
||||
So(s.ReadDoc(), ShouldNotBeEmpty)
|
||||
})
|
||||
}
|
Loading…
Reference in a new issue