Slackbot
08/02/2022, 6:03 AMVampire
08/02/2022, 7:31 AMproject
method you call in there is not the same you call in the top level dependencies
block. Use project.dependencies.project(...)
and it should workVampire
08/02/2022, 7:32 AMTom Clift
08/02/2022, 7:43 AMtesting {
suites {
test {
dependencies {
project.dependencies.project(path: ':test-common', configuration: "testJar")
}
}
}
}
I’m not quite sure what that’s doing… how does that know to add the dependency to the testImplementation
configuration? It looks to me like the equivalent of declaring it in the top-level dependencies
block without a configuration.Vampire
08/02/2022, 10:04 AMimplementation
, now you just create the project dependency but do not add it to the configuration you want to have it in.Tom Clift
08/02/2022, 11:56 PMtesting {
suites {
test {
dependencies {
implementation project.dependencies.project(path: ":test-common", configuration: "testJar")
}
}
}
}
Now that I see the syntax, I understand your original comment and the scoping of the project
method. Thanks again for taking the time to respond.