### Question:
MenuInitializer { public void init() { final Element dropdown = dropdown(); jQuery(dropdown).on("show.bs.dropdown", moveDropDownToBody()); jQuery(dropdown).on("hidden.bs.dropdown", moveDropDownToKebabContainer()); } MenuInitializer(final Element menu,
                           final String dropDownClass); void init();  }### Answer:
@Test public void testInit() { final JQuery jQuery = mock(JQuery.class); final JQuery.CallbackFunction moveDropDownToBody = mock(JQuery.CallbackFunction.class); final JQuery.CallbackFunction moveDropDownToKebabContainer = mock(JQuery.CallbackFunction.class); final Element dropdown = mock(Element.class); doReturn(dropdown).when(initializer).dropdown(); doReturn(moveDropDownToBody).when(initializer).moveDropDownToBody(); doReturn(moveDropDownToKebabContainer).when(initializer).moveDropDownToKebabContainer(); doReturn(jQuery).when(initializer).jQuery(dropdown); initializer.init(); verify(jQuery).on("show.bs.dropdown", moveDropDownToBody); verify(jQuery).on("hidden.bs.dropdown", moveDropDownToKebabContainer); }