@Test
  public void testNullClassLoader() throws Exception {
    System.out.println("\nStarting ClassPathLoaderTest#testNullClassLoader");

    ClassLoader cl = new NullClassLoader();
    String classToLoad = "java.lang.String";

    assertThatThrownBy(() -> {
      Class.forName(classToLoad, true, cl);
    }).isInstanceOf(ClassNotFoundException.class);

    String resourceToGet = "java/lang/String.class";

    URL url = cl.getResource(resourceToGet);
    assertThat(url).isNull();

    InputStream is = cl.getResourceAsStream(resourceToGet);
    assertThat(is).isNull();
  }
Verifies that the {@link NullClassLoader} works and never finds the named class. This is a
control which ensures that tests depending on <tt>NullClassLoader</tt> are valid.
geode-core/src/test/java/org/apache/geode/internal/classloader/ClassPathLoaderTest.java