### Question:
ClassLoaderParentMatcher extends ElementMatcher.Junction.AbstractBase<T> { public boolean matches(T target) { ClassLoader current = classLoader; while (current != null) { if (current == target) { return true; } current = current.getParent(); } return target == null; } ClassLoaderParentMatcher(ClassLoader classLoader); boolean matches(T target); @Override String toString();  }### Answer:
@Test public void testMatch() throws Exception { assertThat(new ClassLoaderParentMatcher<ClassLoader>(child).matches(parent), is(true)); }
@Test public void testMatchBootstrap() throws Exception { assertThat(new ClassLoaderParentMatcher<ClassLoader>(child).matches(null), is(true)); }
@Test public void testNoMatch() throws Exception { assertThat(new ClassLoaderParentMatcher<ClassLoader>(noChild).matches(parent), is(false)); }