The first step is knowing you have a problem with busted repos.
Fix a test broken by exposing more consistent callbacks from repo.init.