* Verify IntegrationServiceObserver invoked during integration service component injection.
*
* @throws Exception
*/
public void testObserverInvoked() throws Exception {
IntegrationServiceObserver mockObserver = Mockito.mock(IntegrationServiceObserver.class);
AuraContext cntx = Aura.getContextService().startContext(Mode.UTEST, Format.JSON, Authentication.AUTHENTICATED);
Integration integration = service.createIntegration("", Mode.UTEST, true, null, getNoDefaultPreloadsApp().getQualifiedName(), mockObserver);
injectSimpleComponent(integration);
Mockito.verify(mockObserver, Mockito.times(2)).contextEstablished(integration, cntx);
}