On Sep 8, 2009, at 9:21 PM, Narco wrote:
<snip>
Hello Hans!
Now I`m having another problem. This behaviour works fine when I
have one
subproject.
afterEvaluate { Project subproject ->
subproject.usePlugin('java')
subproject.tasks.add(name:'compileUnitTests', type:
Compile,
dependsOn: compile){
println subproject.getName() + " TODO: configure
the
unit tests compilation..."
}
subproject.tasks.add(name:'testUnitTests', type: Test,
dependsOn: compileUnitTests){
println subproject.getName() + "TODO: configure
unit
tests..."
}
}
When I have added 2nd project in settings.gradle which does not
differ from
1st project I get build failed:
gradle -C=off testUnitTests
app TODO: configure the unit tests compilation...
Build failed with an exception.
Run with -s or -d option to get more details. Run with -f option to
get the
full
(very verbose) stacktrace.
Build file
'C:\work\perf\SCM\Build\Ant\Project\Release_2_0_1\MDL\build.gradle' l
ine: 64
Failed to notify action.
Cause: Could not find property 'compileUnitTests' on project
':ejb-module-sessio
n'.
What should work is: dependsOn: subproject.tasks.compileUnitTests
(also: dependsOn: subproject.tasks.compile)
- Hans
--
Hans Dockter
Gradle Project Manager
http://www.gradle.org
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email