Search in sources :

Example 1 with CachingDispatcher

use of org.activityinfo.client.dispatch.remote.cache.CachingDispatcher in project activityinfo by bedatadriven.

the class RemoteDispatcherTest method setUp.

@Before
public void setUp() {
    service = createMock("remoteService", RemoteCommandServiceAsync.class);
    proxy = createMock("proxy", CommandCache.class);
    AuthenticatedUser auth = new AuthenticatedUser(AUTH_TOKEN, 1, "alex@alex.com");
    dispatcher = new CachingDispatcher(proxyManager, new MergingDispatcher(new RemoteDispatcher(new MockEventBus(), auth, service), scheduler));
}
Also used : RemoteCommandServiceAsync(org.activityinfo.shared.command.RemoteCommandServiceAsync) CommandCache(org.activityinfo.client.dispatch.CommandCache) CachingDispatcher(org.activityinfo.client.dispatch.remote.cache.CachingDispatcher) MockEventBus(org.activityinfo.client.MockEventBus) AuthenticatedUser(org.activityinfo.shared.auth.AuthenticatedUser) Before(org.junit.Before)

Aggregations

MockEventBus (org.activityinfo.client.MockEventBus)1 CommandCache (org.activityinfo.client.dispatch.CommandCache)1 CachingDispatcher (org.activityinfo.client.dispatch.remote.cache.CachingDispatcher)1 AuthenticatedUser (org.activityinfo.shared.auth.AuthenticatedUser)1 RemoteCommandServiceAsync (org.activityinfo.shared.command.RemoteCommandServiceAsync)1 Before (org.junit.Before)1