Throwing another article out here: Mocks and explicit contracts.
It presents several ways to "inject" dependencies to your functions, specifically by 1) defining the dependency module on your config, 2) passing the dependency's handler function as the caller params, or 3) same as 2 but passing the dependency module altogether.
These three approaches allow you to use mock dependencies for your tests.
My initial guess is to use a combination of behaviors and typespecs.
This article echoes José's Plataformatec article I shared above on dependency injection methods, so I think you can use that as a base. The only thing it left out is for you to validate if a module has adopted a specific behavior. I'm not sure at the specifics on how to do that, though.