bitbucket
bitbucket

Reputation: 1171

Is there a method to output to STDOUT in a Grails Spock test?

I would like to follow the progress of my Grails Spock integration test by outputting to STDOUT at the beginning of each test. So, while the test runs, both log data output from the service and controller, and the output showing the beginning of the test is intermixed.

Example:

Starting test 1

2012-02-09 13:01:41,375 [main] DEBUG  - Adding included service vertex 2 to DAG

2012-02-09 13:01:41,377 [main] DEBUG  - Adding this service vertex 4f34262584ae3fec6cc2d0f0 to DAG

Starting test 2

2012-02-09 13:01:41,377 [main] DEBUG   - Connecting included service vertex 4f34262584ae3fec6cc2d0f0 to 2

2012-02-09 13:01:41,379 [main] DEBUG   - Added all the edges to the DAG for this service 4f34262584ae3fec6cc2d0f0

Starting test 3

...

Upvotes: 3

Views: 2582

Answers (1)

bitbucket
bitbucket

Reputation: 1171

println in cleanup:

grails test-app --echoOut

show the end of the test.

Upvotes: 6

Related Questions