public void verifyAndWait(int waitSecs) {
        verifyUnexpected();

        long timeRemaining = TimeUnit.SECONDS.toMillis(waitSecs);
        final long sleepForMs = 250;
        while (!expectedWithResponses.isEmpty() && timeRemaining > 0) {
            sleep(sleepForMs < timeRemaining ? sleepForMs : timeRemaining);
            timeRemaining -= sleepForMs;
        }
        verify();
    }
Provides a simulator that receives connection over TCP as per a real APNS server.  This class allows verification
and prior configuration of responses in a manner similar to a mocking framework.
src/test/java/com/notnoop/apns/utils/Simulator/ApnsSimulatorWithVerification.java