On 30/03/2011, at 1:28 AM, netextzhwa wrote:

> Hi,
> 
> I want to run my groovy (Geb) test project with gradle. 
> 
> I have all the dependency jar files in a local folder, and want to use
> gradle to build and run the project without needs to connect to internet. 
> 
> The build failed with error:
> Execution failed for task "compileGroovy", you must assign a groovy library
> to the groovy library.
> 
> Any idea on how to do this? (The groovy junit test can be run in eclipse
> without internet connection, but I want to use gradle)
> 
> This is the build script I use:
> 
> apply plugin: 'groovy'
> apply plugin: 'eclipse'
> 
> repositories {
>   // mavenCentral()
> }
> configurations {      
> 
>       compile.transitive = true
>       runtime.transitive = true        
>       
> }
> 
> dependencies {
>       
>       testCompile fileTree(dir: 'locallibs', includes: ['*.jar'])
> //
> //    groovy "org.codehaus.groovy:groovy-all:1.7.5"

You need to tell the groovy plugin which implementation of Groovy you want to 
use. You can use local libraries for this if you like, for example:

groovy files('locallibs/groovy-all.jar')


--
Adam Murdoch
Gradle Developer
http://www.gradle.org
Co-Founder and VP of Engineering, Gradleware Inc. - Gradle Training, Support, 
Consulting
http://www.gradleware.com

Reply via email to