@AfterClass
  public static void afterClass() {
    InternalDistributedSystem ids = InternalDistributedSystem.getAnyInstance();
    if (ids != null) {
      ids.disconnect();
    }
  }
Extracted from TXWriterJUnitTest to share with TXWriterOOMEJUnitTest.
geode-junit/src/main/java/org/apache/geode/TXWriterTestCase.java