code: public static void awaitStackDispose(final SipStack sipStack) {
      await().until(new Runnable() {
  
        @Override
        public void run() {
          try {
            sipStack.dispose();
          } catch (RuntimeException e) {
            e.printStackTrace();
            fail();
          }
        }
      });
    }
docs: Awaits the an error free {@link SipStack#dispose()}.