How do I test a custom task where the execute takes InputChanges?
@TaskAction
fun execute(inputChanges: InputChanges)
val project = ProjectBuilder.builder().build()
val task = project.tasks.create("myTask", MyTask::class.java) {
it.from(...)
it.into(...)
}
task.execute() // What goes here? How can I construct input changes?
Short answer - consider this more of an integration test.
Long answer -basically I have a multi-build project that creates some Plugins, and then in a subproject I want to use those plugins. I can do it with composite builds, but it’s a lot messier than I’d like.
Ideally I’d be able to have this sub-project use the plugins project as a build dependency, but I can’t. I can use it as a regular dependency though, I just don’t have a way to specify input changes. (I don’t care if it’s not actually incremental)