How to determine when a @TaskAction would be executed in relation to existing actions when extending a task?


(thirsch81) #1

Considering the example custom task in the official answer in this post: http://forums.gradle.org/gradle/topics/java_test_task_out_manouvers_itself_into_an_non_up_to_date_state_on_multi_project_builds_with_an_aggregated

How can I be sure, that the method annotated with @TaskAction gets executed only after the built-in Copy action. It seems this example relies on the fact or it will break. When experimenting with this, I could not really figure out the logic behind this. How is a new @TaskAction sorted into the list of actions when extending an existing task type?

Thanks and regards, Thomas