Mockito.when(parentComponent.getComponents()).thenReturn(
Collections.<AbstractComponent> emptyList());
access = new PolicyManagerAccess();
access.setPolicyManager(policyManager);
PolicyContext context = new PolicyContext();
result = new ExecutionResult(context, true, "");
Mockito.when(policyManager.execute(Mockito.anyString(), Mockito.any(PolicyContext.class))).thenReturn(result);
mockComponent = new DummyComponent();
new PlatformAccess().setPlatform(mockPlatform);
Mockito.when(mockPlatform.getPersistenceProvider()).thenReturn(mockProvider);