I've been removing the App and App code to clear the state variables for testing. Is there a faster / easier method?
I was thinking a list or "it" method of setting all used state.xxx variables to "null" but I'm stuck trying to create such code.
I've been removing the App and App code to clear the state variables for testing. Is there a faster / easier method?
I was thinking a list or "it" method of setting all used state.xxx variables to "null" but I'm stuck trying to create such code.
Assuming you know what xxxx is, or could construct a way to iterate a list of possible xxx, you can do state.remove("xxxx")
.
You can do things like this:
state.findAll{it.key.startsWith("m")}.each{log.debug "$it"}