Testing for ActivityCompletionException on ActivityCompletionClient.complete

I’m building a Spring Boot app that, among other things, allows users to call a REST endpoint to trigger completion of activities that called Activity.getExecutionContext().doNotCompleteOnReturn(); . We mostly use this for placeholder activities that are currently executed manually and will later be automated as part of the activity.

I want to test my implementation, and since ActivityCompletionClient.complete documents it throws ActivityCompletionException I looked into what I could do to provoke that.
And I haven’t been very successful so far: I’m using TestWorkflowExtension and registered a workflow that calls an activity that throws an exception after calling doNotCompleteOnReturn(). That forces Temporal into a loop and ends in an ActivityCompletionException as desired. However it takes over a minute to run and that’s not really feasible for a test.

And here’s the crux: if I set timeouts on the workflow and/or activity Temporal just culls the activity, ending in an ActivityNotExistsException instead.

Anybody else has a tip on how to provoke ActivityCompletionException in under a second?