in Kotlin/addCustomManifestPlaceholder/app/build.gradle.kts [14:20]
fun taskAction() {
val manifest = mergedManifest.asFile.get().readText()
// ensure that merged manifest contains the right activity name.
if (!manifest.contains("activity android:name=\"com.android.build.example.minimal.MyRealName\""))
throw RuntimeException("Manifest Placeholder not replaced successfully")
}