server: add TestBecomeStandby
server/v2_client: add func CloseConnections
server: simplify mode transition