summaryrefslogtreecommitdiffhomepage
path: root/test/runner
diff options
context:
space:
mode:
authorgVisor bot <gvisor-bot@google.com>2020-03-04 15:12:26 -0800
committergVisor bot <gvisor-bot@google.com>2020-03-04 15:12:26 -0800
commit4f43d5ecad9fc4e0541b106a874db7fcd87fde8f (patch)
treefb7e01b2a427c73ceff5004cd0759051381ddef9 /test/runner
parenta690b5762480ae80ef4264402fcfa8d84b57339a (diff)
parent504c9e14d61a9ca9fa3615290a05471684019ecc (diff)
Merge pull request #2054 from avagin:gvisor-test
PiperOrigin-RevId: 298951909
Diffstat (limited to 'test/runner')
-rw-r--r--test/runner/gtest/gtest.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/runner/gtest/gtest.go b/test/runner/gtest/gtest.go
index f96e2415e..869169ad5 100644
--- a/test/runner/gtest/gtest.go
+++ b/test/runner/gtest/gtest.go
@@ -66,13 +66,12 @@ func (tc TestCase) Args() []string {
}
if tc.benchmark {
return []string{
- fmt.Sprintf("%s=^$", filterTestFlag),
fmt.Sprintf("%s=^%s$", filterBenchmarkFlag, tc.Name),
+ fmt.Sprintf("%s=", filterTestFlag),
}
}
return []string{
- fmt.Sprintf("%s=^%s$", filterTestFlag, tc.FullName()),
- fmt.Sprintf("%s=^$", filterBenchmarkFlag),
+ fmt.Sprintf("%s=%s", filterTestFlag, tc.FullName()),
}
}
@@ -147,6 +146,8 @@ func ParseTestCases(testBin string, benchmarks bool, extraArgs ...string) ([]Tes
return nil, fmt.Errorf("could not enumerate gtest benchmarks: %v\nstderr\n%s", err, exitErr.Stderr)
}
+ out = []byte(strings.Trim(string(out), "\n"))
+
// Parse benchmark output.
for _, line := range strings.Split(string(out), "\n") {
// Strip comments.