Hello,
I am trying to understand how gradle phases work when I add a type in my task.
I understand that there are 3 phases: 1.Initialization 2.Configuration 3.Execution
and that the Initialization and Configuration phases of all tasks are running every time you are executing a task, regardless of which task you are running.
I have created the below task:
task functionalTests(type: Test) {
group JavaBasePlugin.VERIFICATION_GROUP
description ‘Runs the functional tests.’
include ‘/funcionaltests/tests/’
}
I was expecting that because I haven’t add a “doLast” or “doFirst” the “include ‘/funcionaltests/tests/’” would run during the Configuration phase, but I see that it is running at the Execution phase.
Does the “include” add this step into the Execution phase?
I observed the same with the “type: Exec” and the “commandLine”.