I create a project with grails 2.2.2, add
test "org.seleniumhq.selenium:selenium-firefox-driver:2.28.0"
test "org.seleniumhq.selenium:selenium-support:2.31.0"
test "org.gebish:geb-spock:0.9.0"
test "org.gebish:geb-junit4:0.9.0"
test "org.spockframework:spock-grails-support:0.7-groovy-2.0"
in dependencies in BuildConfig.groovy and
test ":geb:0.9.0"
test(":spock:0.7") {
exclude "spock-grails-support"
}
in plugins in BuildConfig.groovy.
Then I create the functional folder in test folder (add it to classpath), create GebConfig.groovy inside with
import org.openqa.selenium.firefox.FirefoxDriver
driver = {
def driver = new FirefoxDriver()
driver
}
baseUrl = "http://localhost:8080/TestGebSpock/"
I don't create any test whatsoever, just run the test :
test-app :functional
I got this stacktrace and no information about it on the net :
Loading Grails 2.2.2
| Environment set to test.....
| Packaging Grails application.....
| Tests FAILED - view reports in /Users/Fiftoine/workspace/TestGebSpock/target/test-reports
| Error java.lang.NullPointerException
| Error at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
| Error at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
Full stacktrace here : http://pastebin.com/CKtzNJtN
Did anyone have had this error before and solved it? Any help would be appreciated as this is quite simple to reproduce...
Thanks in advance