spockframework/spock-grails — Issue #1: TabLibSpec Out Is Null (Not returned)
Author: bluesliverx
Created: 2012-01-12 19:24:52+00:00
State: open

This may be resolved with Grails 2 since we might not use TagLibSpec...

Currently the code in tag lib spec is this:

```groovy
def invokeTag(String name, Map params = [:], Closure body = null) {
def tag = tagLib."$name"
def out = (tag.maximumNumberOfParameters == 1 ? tag(params) : tag(params, body)).toString()
reset()
out
}
```

It should be this (as some tags do not return the 'out' property at all:

```groovy
def invokeTag(String name, Map params = [:], Closure body = null) {
def tag = tagLib."$name"
if (tag.maximumNumberOfParameters == 1)
tag(params)
else
tag(params, body)
def out = tagLib.out.toString()
reset()
out
}
```