### Question:
CompositeInstrumenter implements Instrumenter { @Override public Object createInstrumentedProxy(Test test, Recorder recorder, Object target) throws NotWrappableTypeException { for (Instrumenter instrumenter : m_instrumenters) { final Object result = instrumenter.createInstrumentedProxy(test, recorder, target); if (result != null) { return result; } } return null; } CompositeInstrumenter(Instrumenter... instrumenters);  CompositeInstrumenter(List<Instrumenter> instrumenters); @Override Object createInstrumentedProxy(Test test,
                                                  Recorder recorder,
                                                  Object target); @Override boolean instrument(Test test,
                                      Recorder recorder,
                                      Object target); @Override boolean instrument(Test test,
                                      Recorder recorder,
                                      Object target,
                                      InstrumentationFilter filter); @Override String getDescription();  }### Answer:
@Test public void testCreateInstrumentedProxy() throws Exception { when(m_instrumenter2.createInstrumentedProxy(m_test, m_recorder, m_target)) .thenReturn(m_target); final Instrumenter instrumenter = new CompositeInstrumenter(m_instrumenter1, m_instrumenter2); instrumenter.createInstrumentedProxy(m_test, m_recorder, m_target); final InOrder inOrder = inOrder(m_instrumenter1, m_instrumenter2); inOrder.verify(m_instrumenter1) .createInstrumentedProxy(m_test, m_recorder, m_target); inOrder.verify(m_instrumenter2) .createInstrumentedProxy(m_test, m_recorder, m_target); verifyNoMoreInteractions(m_instrumenter1, m_instrumenter2); }
@Test public void testCreateInstrumentedProxyWithNull() throws Exception { final Instrumenter instrumenter = new CompositeInstrumenter(asList(m_instrumenter1, m_instrumenter2)); final Object result = instrumenter.createInstrumentedProxy(m_test, m_recorder, null); assertNull(result); }
@Test public void testCreateInstrumentedProxyFailure() throws Exception { final Instrumenter instrumenter = new CompositeInstrumenter(asList(m_instrumenter1, m_instrumenter2)); final Object result = instrumenter.createInstrumentedProxy(m_test, m_recorder, m_target); assertNull(result); }