Search code examples
groovyready-api

ReadyAPI - How to filter by testStep name in TestRunListener.afterStep event handler Target


I'm trying to add a filter for the TestRunListener.afterSetp event handler. I want to filter it by the current testStep name. Let's say, testStep.Name.contains("XXX").

How can I get the current testStep name in the Target Column?

context.getCurrentStep().getLabel() doesn't work

enter image description here enter image description here


Solution

  • From official documentation:

    Enter RegexRequest.* so that the event is applied only to test items that start with RegexRequest.

    So in your case you could use .*XXX.*.