Or edit this:
@Keyword
public void pandemic(List<String> keywordsToAdd = []) {
this.markKeywords(keywordsToAdd)
Set<String> influencedKeywords = this.getHighlightingKeywords()
WebUiBuiltInKeywords.metaClass.'static'.invokeMethod = { String name, args ->
if (name in influencedKeywords) {
TestObject to = (TestObject)args[0]
HighlightElement.on(to)
}
def result
try {
result = delegate.metaClass.getMetaMethod(name, args).invoke(delegate, args)
} catch(Exception e) {
System.out.println("Handling exception for method $name")
}
return result
}
}
to:
@Keyword
public void pandemic(List<String> keywordsToAdd = []) {
this.markKeywords(keywordsToAdd)
Set<String> influencedKeywords = this.getHighlightingKeywords()
WebUiBuiltInKeywords.metaClass.'static'.invokeMethod = { String name, args ->
if (name in influencedKeywords) {
TestObject to = (TestObject)args[0]
HighlightElement.on(to)
}
return delegate.metaClass.getMetaMethod(name, args).invoke(delegate, args)
}
}