return runJUnit4Test(scriptClass);
}
for (Map.Entry<String, GroovyRunner> entry : GroovySystem.RUNNER_REGISTRY.entrySet()) {
GroovyRunner runner = entry.getValue();
if (runner != null && runner.canRun(scriptClass, this.loader)) {
return runner.run(scriptClass, this.loader);
}
}
String message = "This script or class could not be run.\n" +
"It should either:\n" +
"- have a main method,\n" +