Merge "Add phony name for robolectric tests" am: ffe2c918e9

Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1831866

Change-Id: I94f283455b3ddecad3d932d7bdbdab902ff211ee
This commit is contained in:
Colin Cross
2021-09-24 20:08:33 +00:00
committed by Automerger Merge Worker

View File

@@ -212,7 +212,13 @@ func (r *robolectricTest) GenerateAndroidBuildActions(ctx android.ModuleContext)
installDeps = append(installDeps, installedData)
}
ctx.InstallFile(installPath, ctx.ModuleName()+".jar", r.combinedJar, installDeps...)
installed := ctx.InstallFile(installPath, ctx.ModuleName()+".jar", r.combinedJar, installDeps...)
if r.ExportedToMake() {
// Soong handles installation here, but Make is usually what creates the phony rule that atest
// uses to build the module. Create it here for now.
ctx.Phony(ctx.ModuleName(), installed)
}
}
func generateRoboTestConfig(ctx android.ModuleContext, outputFile android.WritablePath,