You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@grails.apache.org by "jdaugherty (via GitHub)" <gi...@apache.org> on 2026/09/01 18:13:32 UTC
[I] Test succeeds in Grails 2.3.1, but fails in IntelliJ [grails-intellij-plugin]
jdaugherty opened a new issue, #146:
URL: https://github.com/apache/grails-intellij-plugin/issues/146
This my test:
```
void "Test the create action returns the correct model"() {
when: "The create action is executed"
controller.create()
then: "The model is correctly created"
model.erikInstance != null
}
```
With the following implementation:
```
def create() {
respond new Erik(params)
}
```
Fails with the following error:
```
Condition not satisfied:
model.erikInstance != null
| | |
| null false
[erik:nl.oelan.farmacie.declaratie.Erik : (unsaved)]
at nl.oelan.farmacie.declaratie.ErikControllerSpec.Test the create action returns the correct model(ErikControllerSpec.groovy:36)
```
As you can see, the 'respond' keyword, which is newly introduced in 2.3, behaves a bit bit odd in IntelliJ. I've run the same test using Grails command line:
grails test-app :unit nl.oelan.farmacie.declaratie.ErikController
and using that, it works.
---
*Imported from [IDEA-115932](https://youtrack.jetbrains.com/issue/IDEA-115932) · Type: Bug · Votes: 0*
*Comments, attachments, dates and reporter are not part of the export — follow the link above for the full history.*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@grails.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org