Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>What version of grails are you using? It's working fine for both situations for me on 1.0.4 (the latest).</p> <p>I create a new blank app and created a service class with an integration test:</p> <p>FooService.groovy: </p> <pre><code>class FooService { def logSomething(message) { log.error(message) return true } } </code></pre> <p>FooServiceTests.groovy:</p> <pre><code>class FooServiceTests extends GroovyTestCase { def fooService void testSomething() { assert fooService.logSomething("it works") } } </code></pre> <p>When running just test-app, I get the log message: </p> <pre><code>% grails test-app Welcome to Grails 1.0.4 - http://grails.org/ .... ------------------------------------------------------- Running 1 Integration Test... Running test FooServiceTests... testSomething...[4174] service.FooService it works SUCCESS Integration Tests Completed in 440ms ------------------------------------------------------- ... </code></pre> <p>When running only integration tests, it also works:</p> <pre><code>% grails test-app -integration Welcome to Grails 1.0.4 - http://grails.org/ .... ------------------------------------------------------- Running 1 Integration Test... Running test FooServiceTests... testSomething...[4444] service.FooService it works SUCCESS Integration Tests Completed in 481ms ------------------------------------------------------- .... </code></pre> <p>Are you munging around with the logger class (or overriding any metaclass stuff on the logger, in any previous integration classes or unit tests and not then re-initializing the metaClass?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload