Mocking child workflows in Java

Hello,

I am trying to figure out how to test some complex workflows.
I have a MainWorkflow that drives an execution and trigger several child workflows.
I would like to unit test MainWorkflow logic and do not care about child workflows as I will be creating separate unit tests for them.
Activities mocking is simple as I am registering activity instances to the worker (and I can mock them with mockito) but with workflows I have to register classes.
I didn’t find any tool for such workflow mocking in the TestWorkflowEnvironment.
I will be grateful for the hints.
SDK version: 1.14.0

thanks
Lukasz

See testMockedChild sample.

Thank you @maxim. Somehow I missed that example.