api / org.gradle.testkit.runner / BuildResult / task

task

abstract fun task(taskPath: String): BuildTask

Returns the result object for a particular task, or null if the given task was not part of the build.

Parameters

taskPath - the path of the target task

Return
information about the executed task, or null if the task was not executed