So I'm left with a failing test, as this fixture has some expectations
on the concrete test class which fail.
-----
Information:Compilation completed with 1 error and 0 warnings
Information:1 error
Information:0 warnings
Error:java.lang.NoSuchMethodError:
org.codehaus.groovy.ast.ModuleNode.getImport(Ljava/lang/String;)Lorg/
codehaus/groovy/ast/ClassNode;
at org.spockframework.compiler.EarlyTransform.nameResolvesToType
(EarlyTransform.java:81)
at org.spockframework.compiler.EarlyTransform.hasSpecAnnotation
(EarlyTransform.java:64)
at
org.spockframework.compiler.EarlyTransform.moduleContainsClassWithSpecAnnotation
(EarlyTransform.java:52)
at org.spockframework.compiler.EarlyTransform.visit
(EarlyTransform.java:42)
at org.codehaus.groovy.transform.ASTTransformationVisitor$3.call
(ASTTransformationVisitor.java:268)
at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits
(CompilationUnit.java:810)
at org.codehaus.groovy.control.CompilationUnit.compile
(CompilationUnit.java:470)
at org.jetbrains.groovy.compiler.rt.GroovyCompilerWrapper.compile
(GroovyCompilerWrapper.java:41)
at org.jetbrains.groovy.compiler.rt.GroovycRunner.main
(GroovycRunner.java:128)
-----
//BUG Can't define this as abstract because of a groovy bug:
http://jira.codehaus.org/browse/GROOVY-3318
// Can't ignore because then Spocks AST process fails.
@Ignore
/*abstract*/ class DroolsGroovyTestFixture extends Specification
{ .. }
which versions of Spock and Groovy are you using?
Cheers,
Peter
groovy-1.7-beta2
spock 0.3
It seems that I get this error for any annotation (eg, @Mixin)
Spock 0.3 only works with Groovy 1.6. For 1.7 (preferably rc-2) you have to use spock-core-0.4-groovy-1.7-SNAPSHOT, which is available from http://m2repo.spockframework.org/snapshots. Spock 0.4 release will come in two flavors for Groovy 1.6 and 1.7, respectively.
Please let me know if this solves your problem.
Cheers,
Peter
> --
>
> You received this message because you are subscribed to the Google Groups "Spock Framework" group.
> To post to this group, send email to spockfr...@googlegroups.com.
> To unsubscribe from this group, send email to spockframewor...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/spockframework?hl=en.
>
>
On 18.12.2009, at 02:47, Barry Kaplan wrote:
> Ok, just upped to 0.4-snapshot and this issue seems to be resolved.
> Don't know how I got so behind in versions. Sorry for the noise.
>