rebase: update packages in go.mod to latest releases

updated few packages in go.mod to latest
available release.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
Madhu Rajanna
2021-06-04 14:29:18 +05:30
committed by mergify[bot]
parent 0f44c6acb7
commit fb7dc13dfe
590 changed files with 28243 additions and 6376 deletions

View File

@ -4,6 +4,7 @@ import (
"math/rand"
"regexp"
"sort"
"strings"
)
type Specs struct {
@ -46,11 +47,11 @@ func (e *Specs) Shuffle(r *rand.Rand) {
e.names = names
}
func (e *Specs) ApplyFocus(description string, focusString string, skipString string) {
if focusString == "" && skipString == "" {
func (e *Specs) ApplyFocus(description string, focus, skip []string) {
if len(focus)+len(skip) == 0 {
e.applyProgrammaticFocus()
} else {
e.applyRegExpFocusAndSkip(description, focusString, skipString)
e.applyRegExpFocusAndSkip(description, focus, skip)
}
}
@ -90,14 +91,13 @@ func (e *Specs) toMatch(description string, i int) []byte {
}
}
func (e *Specs) applyRegExpFocusAndSkip(description string, focusString string, skipString string) {
var focusFilter *regexp.Regexp
if focusString != "" {
focusFilter = regexp.MustCompile(focusString)
func (e *Specs) applyRegExpFocusAndSkip(description string, focus, skip []string) {
var focusFilter, skipFilter *regexp.Regexp
if len(focus) > 0 {
focusFilter = regexp.MustCompile(strings.Join(focus, "|"))
}
var skipFilter *regexp.Regexp
if skipString != "" {
skipFilter = regexp.MustCompile(skipString)
if len(skip) > 0 {
skipFilter = regexp.MustCompile(strings.Join(skip, "|"))
}
for i, spec := range e.specs {