public static Logger ensureGroovyLog() {
synchronized (threadPool) {
if (!checkedGroovyLogMonitor || launchedTestRunner) {
groovyLogger = Logger.getLogger("groovy.log");
Log4JMonitor logMonitor = getLogMonitor();
if (logMonitor != null && !logMonitor.hasLogArea("groovy.log")) {
logMonitor.addLogArea("script log", "groovy.log", false);
checkedGroovyLogMonitor = true;
} else if (logMonitor == null && launchedTestRunner) {
checkedGroovyLogMonitor = true;
launchedTestRunner = false;
}