private EventBus eventBus;
private MultiActivityManager activityManager;
@Before
public void setUp() throws Exception {
final ClientFactory clientFactory = mock( ClientFactory.class );
NavigationViewFactory navigationViewFactory = mock(NavigationViewFactory.class);
PerspectivesPanelView perspectivesPanelView = mock( PerspectivesPanelView.class );
when(
clientFactory.getNavigationViewFactory()
).thenReturn(
navigationViewFactory
);
when(
clientFactory.getNavigationViewFactory().getPerspectivesPanelView()
).thenReturn(
perspectivesPanelView
);
PerspectiveFactory perspectiveFactory = mock(PerspectiveFactory.class);
when(
clientFactory.getPerspectiveFactory()
).thenReturn(
perspectiveFactory
);
when(
perspectiveFactory.getRegisteredPerspectiveTypes()
).thenReturn(
new String[]{"author", "runtime"}
);
placeController = mock( PlaceController.class );
when(
clientFactory.getPlaceController()
).thenReturn(
placeController
);
ConfigurationServiceAsync configurationService = mock( ConfigurationServiceAsync.class );
when(
clientFactory.getConfigurationService()
).thenReturn(
configurationService
);
activityManager = mock( MultiActivityManager.class );
when(
clientFactory.getActivityManager()
).thenReturn(
activityManager
);
placeHistoryHandler = mock( PlaceHistoryHandler.class );
when(
clientFactory.getPlaceHistoryHandler()
).thenReturn(
placeHistoryHandler
);
eventBus = mock( EventBus.class );