Connecting source sets
By default, Apollo Kotlin adds generated sources:
- to the
main
sourceSet for JVM projects - to
commonMain
for multiplatform projects - to all non-test variants for Android projects
You can customize this behavior with the outputDirConnection
property. For example, to wire a service to the test source set of a Kotlin JVM project:
apollo {service("service") {outputDirConnection {connectToKotlinSourceSet("test")}}}