Compile mock closures with mockserver classloader
Change-Id: Ic57efa8017650f308c1862dce418b629262a3ef7
This commit is contained in:
parent
3763628379
commit
ee42225e9c
1 changed files with 2 additions and 1 deletions
|
@ -64,7 +64,8 @@ class Mock implements Comparable<Mock> {
|
|||
}
|
||||
|
||||
private Closure toClosure(String predicate) {
|
||||
return Eval.me(predicate) as Closure
|
||||
GroovyShell sh = new GroovyShell(this.class.classLoader);
|
||||
return sh.evaluate(predicate) as Closure
|
||||
}
|
||||
|
||||
void setResponse(String response) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue