I’m writing a custom plugin that adds a custom task. I’d like to perform some integration tests to ensure that the task produces the correct outputs.
I’ve looked into using TestKit, but as far as I can tell this only allows me to validate output written to the console. It appears that the actual Gradle Build is using its own internal infrastructure to perform integration tests. I’d like to validate all the inputs and outputs of the task.
I could use the tooling API, but then I would need to manage the classpath for the tests. I’m also not sure if this is the right path since TestKit states it will be adding more features later.
What is the best way to write tests that can validate all the outputs of custom tasks of a custom plugin?