Testing with workflow interceptors

I’m trying to implement a workflow interceptor that intercepts all activity failures and pages our oncall engineer who can then send a signal to either fail or retry the activity. I’m following this example here.

I’d like to write unit tests to simulate activity failures being intercepted but I’m not able to figure out an easy way to do this. Are there examples already for this? Any pointers would be much appreciated.

What is the exact issue you are facing?