// Regression test for root cause of https://github.com/nasa/mct/issues/281
String id = "someTestUser";
CoreComponentRegistry mockRegistry = Mockito.mock(CoreComponentRegistry.class);
Mockito.when(mockPlatform.getComponentRegistry()).thenReturn(mockRegistry);
Mockito.when(mockRegistry.newInstance(Mockito.anyString()))
.thenAnswer(new Answer<AbstractComponent>() {
@Override
public AbstractComponent answer(InvocationOnMock invocation) throws Throwable {
return AbstractComponent.class.cast(
Class.forName(invocation.getArguments()[0].toString()).newInstance()