From 4e128282f2cc79d33d74c4c6d9773f8b9e610ea1 Mon Sep 17 00:00:00 2001 From: Pirama Arumuga Nainar Date: Fri, 1 Mar 2019 14:43:39 -0800 Subject: [PATCH] Enable coverage universally if COVERAGE_PATHS includes "*" http://b/116873221 This will be used in a target in the build server to build all native code with coverage. Test: 'm NATIVE_COVERAGE=true COVERAGE_PATHS=* nothing' works as expected. Change-Id: I55d644ed9212c4ab0f1e4a00aac3a467fcf2a463 --- android/config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/config.go b/android/config.go index 24be10a96..92879de08 100644 --- a/android/config.go +++ b/android/config.go @@ -862,7 +862,7 @@ func (c *deviceConfig) NativeCoverageEnabled() bool { func (c *deviceConfig) CoverageEnabledForPath(path string) bool { coverage := false if c.config.productVariables.CoveragePaths != nil { - if PrefixInList(path, c.config.productVariables.CoveragePaths) { + if InList("*", c.config.productVariables.CoveragePaths) || PrefixInList(path, c.config.productVariables.CoveragePaths) { coverage = true } }