Saturday, August 24, 2013

Spock integration test in Grails not running

Spock integration test in Grails not running

I am trying to write a Grail integration test using Spock. Here is my test...
class UserControllerIntegrationSpec extends
grails.plugin.spock.IntegrationSpec {
def "test user login" () {
setup:
def mc = new UserController()
mc.request.parameters = [username:'tester@gmail.com',
password:'stav'];
when:
mc.login()
then:
def responseString = mc.response.contentAsString
responseString.indexOf("transaction") > 0
}
}
The test is in the correct integration folder.
To run, I do
grails test-app integration:spock
The command line tells me test passes but there is no details of any test
in the test-reports.
What stupid thing are my doing wrong?
Thanks

No comments:

Post a Comment