We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f063112 commit 106400dCopy full SHA for 106400d
internal/cmd/generate/commands/gentests/model.go
@@ -293,11 +293,15 @@ func (ts TestSuite) SkipEsVersion(minmax string) bool {
293
// BaseFilename returns the original filename in form of `foo/10_bar.yml`.
294
//
295
func (t Test) BaseFilename() string {
296
+ var index int
297
parts := strings.Split(t.Filepath, string(filepath.Separator))
- if len(parts) < 2 {
298
- return ""
+ for i, v := range parts {
299
+ index = i
300
+ if v == "rest-api-spec" {
301
+ break
302
+ }
303
}
- return strings.Join(parts[len(parts)-2:], string(filepath.Separator))
304
+ return strings.Join(parts[index+2:], string(filepath.Separator))
305
306
307
// SkipEsVersion returns true if the test should be skipped.
0 commit comments