Amend examples (#211)

This commit is contained in:
Janos Dobronszki
2021-09-21 16:36:39 +01:00
committed by GitHub
parent 80a253ada5
commit ba6220fd01
61 changed files with 920 additions and 918 deletions

View File

@@ -264,7 +264,9 @@ func main() {
fmt.Println(string(exam), err)
os.Exit(1)
}
if len(service.Spec.Paths) != len(m) {
fmt.Printf("Service has %v endpoints, but only %v examples\n", len(service.Spec.Paths), len(m))
}
for endpoint, examples := range m {
for _, example := range examples {
title := regexp.MustCompile("[^a-zA-Z0-9]+").ReplaceAllString(strcase.LowerCamelCase(strings.Replace(example.Title, " ", "_", -1)), "")