From f6856b09daa7e23c533f8fc9c2b1ae5c25b420fb Mon Sep 17 00:00:00 2001 From: qiulaidongfeng <2645477756@qq.com> Date: Fri, 8 Mar 2024 21:40:09 +0800 Subject: [PATCH] testing: remove matchMutex Change-Id: Ia5424fbda2c385a9f8b559fb38fcd4e596e905a3 --- src/testing/match.go | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/testing/match.go b/src/testing/match.go index 84804dc2ecf..93eb4fa8ae1 100644 --- a/src/testing/match.go +++ b/src/testing/match.go @@ -44,10 +44,6 @@ type simpleMatch []string // alternationMatch matches a test name if one of the alternations match. type alternationMatch []filterMatch -// TODO: fix test_main to avoid race and improve caching, also allowing to -// eliminate this Mutex. -var matchMutex sync.Mutex - func allMatcher() *matcher { return newMatcher(nil, "", "", "") } @@ -90,9 +86,6 @@ func (m *matcher) fullName(c *common, subname string) (name string, ok, partial name = m.unique(c.name, rewrite(subname)) } - matchMutex.Lock() - defer matchMutex.Unlock() - // We check the full array of paths each time to allow for the case that a pattern contains a '/'. elem := strings.Split(name, "/")