@Test
public void createConnectionInClosedState() {

    new TestKit(actorSystem) {{
        final TestProbe probe = TestProbe.apply(actorSystem);
        final ActorRef underTest =
                TestConstants.createConnectionSupervisorActor(connectionId, actorSystem, pubSubMediator,
                        proxyActor,
                        (connection, concierge, connectionActor) -> MockClientActor.props(probe.ref()));
        watch(underTest);
        // create connection
        underTest.tell(createClosedConnection, getRef());
        expectMsg(createClosedConnectionResponse);
        // assert that client actor is not called for closed connection
        probe.expectNoMessage();
    }};
}