Grails 2.0.0 and spock:0.6-SNAPSHOT Feature methods cannot be called from user code error
16 views
Skip to first unread message
Jacqui Snook
unread,
Dec 21, 2011, 9:14:37 AM12/21/11
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Spock Framework - User
Hi,
I am trying to use Spock with Grails 2.0.0 but I get the following
exception with every test that is run even the most simple ones:
Feature methods cannot be called from user code
org.spockframework.runtime.InvalidSpecException: Feature methods
cannot be called from user code
at
org.spockframework.runtime.SpockRuntime.featureMethodCalled(SpockRuntime.java:
80)
This is an example of a really simple test which throws this
exception:
class BasicTests extends Specification {
def "test broken"() {
when:
def result = 2 + 2
then:
4 == result
}
}
btw., It makes no difference if I add the @TestFor annotations or not.
Anyone have any idea why this is not running?
Many thanks in advance.
Luke Daley
unread,
Jan 3, 2012, 7:35:15 AM1/3/12
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to spockfr...@googlegroups.com
No idea sorry, any chance you could share a reproducible sample?