Clone
Adam Brown <acourtneybrown@users.noreply.github.com>
committed
on 22 Mar 18
Allow creation of Task with constructor arguments (#4809)
* Allow creation of Task with constructor arguments

Rough spike on exposing cons… Show more
Allow creation of Task with constructor arguments (#4809)

* Allow creation of Task with constructor arguments

Rough spike on exposing constructor arguments in Task creation DSL

Fixed codestyle failure

Fixed binary compatibility failure

Fixed docs checkstyle on Task.TASK_PARAMS

Fixed infinite recursion

Fixed "broken" tests

Rename TASK_PARAMS to TASK_CONSTRUCTOR_ARGS

Add TaskContainer.create(String, Class<>, Object...)

Add better description to TaskContainer.create(String, Class, Object...)

Add @since & @Incubating to TaskContainer.create(String, Class, Object...)

Ignore some tests of DependencyInjectingInstantiator whose output *should* change

Fix tests in DefaultTaskContainerTest

Avoid explicit cast of DirectInstantiator.INSTANCE to DirectInstantiator

Back out addition of NamedEntityInstantiator.create(String, Class, Object...)

Fix omitting constructorArgs from previous cleanup

Revert DefaultTaskCollection.create(String, Class) to use instantiator

Revert optimize import

Fail if constructorArgs is not a List<> or Object[]

Remove handling of non-@Inject constructor with constructor args

Revert DependencyInjectingInstantiatorTest

Move TaskInternal logic from DefaultTaskContainer to TaskFactory

Make ITaskFactory extend NamedEntityInstantiator again

* Fix AnnotationProcessingTaskFactory.create(String, Class) double-processing

* Update DefaultTaskContainerTest to use ITaskFactory.createTask() for some mocks

* Reduce size of ITaskFactory interface

* Add DefaultTaskContainer.createTask() to avoid adding task multiple times

* Fix test failures related to removing ITaskFactory.createTask(Map)

* Optimize imports

* Optimize imports

* Fix test failures related to removing ITaskFactory.createTask(Map)

* Add tests for Task constructor arguments in Groovy build script

* Add tests for Task constructor arguments in Java plugin via API

* Add tests for Task constructor arguments in Kotlin build script

* Add tests that check for constructorArgs being List or Object[]

Show less

master + 399 more