This accessor does more that its name implies, as it attempts to create a peer if it doesn't exists which males the API confusing. This was intended to be a test only method, but it sneaked outside of its original scope.
This diff simplifies `getPeerId()` by making it a simple accessor, and use `registerProof()` instead when this is the expected behavior.
Ref T1854.