add tests for reconnecting, failover