final IPortletEntity portletEntity = createMock(IPortletEntity.class);
final IPortletEntityRegistry portletEntityRegistry = createMock(IPortletEntityRegistry.class);
expect(portletEntityRegistry.getOrCreatePortletEntity(portDef1, "sub1", 1)).andReturn(portletEntity);
final IPortletWindowId portletWindowId = new MockPortletWindowId("win1");
final IPortletWindowRegistry portletWindowRegistry = createMock(IPortletWindowRegistry.class);
final IPortletRenderer portletRenderer = createMock(IPortletRenderer.class);
expect(portletRenderer.doInit(portletEntity, null, portalControlStructures.getHttpServletRequest(), response))