Merge "Make native_coverage clause work with ClangCoverage"

This commit is contained in:
Colin Cross
2020-06-23 03:06:53 +00:00
committed by Gerrit Code Review
8 changed files with 26 additions and 12 deletions

View File

@@ -1556,7 +1556,7 @@ func (a *apexBundle) AddSanitizerDependencies(ctx android.BottomUpMutatorContext
var _ cc.Coverage = (*apexBundle)(nil)
func (a *apexBundle) IsNativeCoverageNeeded(ctx android.BaseModuleContext) bool {
return ctx.Device() && (ctx.DeviceConfig().NativeCoverageEnabled() || ctx.DeviceConfig().ClangCoverageEnabled())
return ctx.Device() && ctx.DeviceConfig().NativeCoverageEnabled()
}
func (a *apexBundle) PreventInstall() {

View File

@@ -118,6 +118,7 @@ func TestVndkApexUsesVendorVariant(t *testing.T) {
t.Run("VNDK APEX supports coverage variants", func(t *testing.T) {
ctx, _ := testApex(t, bp, func(fs map[string][]byte, config android.Config) {
config.TestProductVariables.GcovCoverage = proptools.BoolPtr(true)
config.TestProductVariables.Native_coverage = proptools.BoolPtr(true)
})