aspose file tools*
The moose likes Groovy and the fly likes [Grails] Why my test isn't passed successfully? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » Groovy
Bookmark "[Grails] Why my test isn Watch "[Grails] Why my test isn New topic
Author

[Grails] Why my test isn't passed successfully?

Hussein Baghdadi
clojure forum advocate
Bartender

Joined: Nov 08, 2003
Posts: 3479

Hey,
I'm writing unit tests to my domain entities.
Installation, User (one-to-many)
User, Group (one-to-many)

The last assert fails although I created a valid object, I got this message:
junit.framework.AssertionFailedError
at com.domain.GroupTests.testConstraints(GroupTests.groovy:30)
at _GrailsTest_groovy$_run_closure4.doCall(_GrailsTest_groovy:262)
at _GrailsTest_groovy$_run_closure4.call(_GrailsTest_groovy)
at _GrailsTest_groovy$_run_closure2.doCall(_GrailsTest_groovy:221)
at _GrailsTest_groovy$_run_closure1_closure21.doCall(_GrailsTest_groovy:181)
at _GrailsTest_groovy$_run_closure1.doCall(_GrailsTest_groovy:168)
at TestApp$_run_closure1.doCall(TestApp.groovy:102)
at gant.Gant$_dispatch_closure4.doCall(Gant.groovy:324)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy:334)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:344)
at gant.Gant.this$2$withBuildListeners(Gant.groovy)
at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:334)
at gant.Gant.this$2$dispatch(Gant.groovy)
at gant.Gant.invokeMethod(Gant.groovy)
at gant.Gant.processTargets(Gant.groovy:495)
at gant.Gant.processTargets(Gant.groovy:480)

I also tried this:

And I got this:
[]
junit.framework.AssertionFailedError: []
at sy.inet.bulksend.GroupTests.testConstraints(GroupTests.groovy:30)
at _GrailsTest_groovy$_run_closure4.doCall(_GrailsTest_groovy:262)
at _GrailsTest_groovy$_run_closure4.call(_GrailsTest_groovy)
at _GrailsTest_groovy$_run_closure2.doCall(_GrailsTest_groovy:221)
at _GrailsTest_groovy$_run_closure1_closure21.doCall(_GrailsTest_groovy:181)
at _GrailsTest_groovy$_run_closure1.doCall(_GrailsTest_groovy:168)
at TestApp$_run_closure1.doCall(TestApp.groovy:102)
at gant.Gant$_dispatch_closure4.doCall(Gant.groovy:324)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy:334)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:344)
at gant.Gant.this$2$withBuildListeners(Gant.groovy)
at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:334)
at gant.Gant.this$2$dispatch(Gant.groovy)
at gant.Gant.invokeMethod(Gant.groovy)
at gant.Gant.processTargets(Gant.groovy:495)
at gant.Gant.processTargets(Gant.groovy:480)

Platform:
OS X 10.6.2
JDK 1.6 u17
Grails 1.2.0

Thanks for help and time.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: [Grails] Why my test isn't passed successfully?