How to check matching string using IsMatch activity?

I need to check if my input Status string matches with any of the statuses like PASS, FAIL, BLOCKED, UNEXECUTED . How do I do this using RegEx with IsMatch activity?
I appreciate any inputs here. Thanks :slight_smile:

1 Like

Can you provide examples of your input status strings? If they only contain one of “PASS”, “FAIL”, “BLOCKED”, or “UNEXECUTED”, then you can use a Switch case to better handle each of these.


If your input string just contains those exact statuses, you could create an array variable with this value: {"PASS", "FAIL", "BLOCKED", "UNEXECUTED"} and then you just use it like: array.Contains(yourInputStatus)

If your input status can contain other things, this regex might do the trick:
It will validate a string that contains any of the status with or without other text at start or end. The i flag at the end is to make it case insensitive