private void loadSanctionedSerializables(Class<?> clazz) {
    try (InputStream expectedSerializablesStream =
        getResourceAsStream(clazz, expectedSerializablesFileName)) {
      // the expectedSerializablesStream will be automatically closed when we exit this block
      expectedSerializables.addAll(
          CompiledClassUtils.loadClassesAndVariables(expectedSerializablesStream));
    } catch (IOException e) {
      throw new UncheckedIOException(e);
    }
  }
This subclass of AbstractAnalyzeSerializablesTestBase uses DataSerializer and
InternalDataSerializer. It also performs initialization of the Geode TypeRegistry
geode-junit/src/main/java/org/apache/geode/codeAnalysis/AnalyzeSerializablesTestBase.java