Search in sources :

Example 6 with Synchroniser

use of org.jmock.lib.concurrent.Synchroniser in project geode by apache.

the class GfshCommandJUnitTest method setup.

@Before
public void setup() {
    mockContext = new Mockery();
    mockContext.setImposteriser(ClassImposteriser.INSTANCE);
    mockContext.setThreadingPolicy(new Synchroniser());
    defaultGfshCommmand = new DefaultGfshCommmand();
}
Also used : Synchroniser(org.jmock.lib.concurrent.Synchroniser) Mockery(org.jmock.Mockery) Before(org.junit.Before)

Example 7 with Synchroniser

use of org.jmock.lib.concurrent.Synchroniser in project geode by apache.

the class AutoBalancerJUnitTest method setupMock.

@Before
public void setupMock() {
    mockContext = new Mockery() {

        {
            setImposteriser(ClassImposteriser.INSTANCE);
            setThreadingPolicy(new Synchroniser());
        }
    };
    mockCacheFacade = mockContext.mock(CacheOperationFacade.class);
    mockAuditor = mockContext.mock(OOBAuditor.class);
    mockScheduler = mockContext.mock(AuditScheduler.class);
    mockClock = mockContext.mock(TimeProvider.class);
}
Also used : TimeProvider(org.apache.geode.cache.util.AutoBalancer.TimeProvider) CacheOperationFacade(org.apache.geode.cache.util.AutoBalancer.CacheOperationFacade) SizeBasedOOBAuditor(org.apache.geode.cache.util.AutoBalancer.SizeBasedOOBAuditor) OOBAuditor(org.apache.geode.cache.util.AutoBalancer.OOBAuditor) AuditScheduler(org.apache.geode.cache.util.AutoBalancer.AuditScheduler) Synchroniser(org.jmock.lib.concurrent.Synchroniser) Mockery(org.jmock.Mockery) Before(org.junit.Before)

Example 8 with Synchroniser

use of org.jmock.lib.concurrent.Synchroniser in project geode by apache.

the class ClientHttpRequestJUnitTest method setUp.

@Before
public void setUp() {
    mockContext = new Mockery();
    mockContext.setImposteriser(ClassImposteriser.INSTANCE);
    mockContext.setThreadingPolicy(new Synchroniser());
}
Also used : Synchroniser(org.jmock.lib.concurrent.Synchroniser) Mockery(org.jmock.Mockery) Before(org.junit.Before)

Example 9 with Synchroniser

use of org.jmock.lib.concurrent.Synchroniser in project geode by apache.

the class ServerLauncherTest method setup.

@Before
public void setup() {
    mockContext = new Mockery() {

        {
            setImposteriser(ClassImposteriser.INSTANCE);
            setThreadingPolicy(new Synchroniser());
        }
    };
    DistributedSystem.removeSystem(InternalDistributedSystem.getConnectedInstance());
}
Also used : Synchroniser(org.jmock.lib.concurrent.Synchroniser) Mockery(org.jmock.Mockery) Before(org.junit.Before)

Example 10 with Synchroniser

use of org.jmock.lib.concurrent.Synchroniser in project geode by apache.

the class DescribeDiskStoreFunctionJUnitTest method setup.

@Before
public void setup() {
    mockContext = new Mockery();
    mockContext.setImposteriser(ClassImposteriser.INSTANCE);
    mockContext.setThreadingPolicy(new Synchroniser());
}
Also used : Synchroniser(org.jmock.lib.concurrent.Synchroniser) Mockery(org.jmock.Mockery) Before(org.junit.Before)

Aggregations

Mockery (org.jmock.Mockery)14 Synchroniser (org.jmock.lib.concurrent.Synchroniser)14 Before (org.junit.Before)12 File (java.io.File)2 Expectations (org.jmock.Expectations)2 EmailDestination (i2p.bote.email.EmailDestination)1 I2PSendQueue (i2p.bote.network.I2PSendQueue)1 IndexPacket (i2p.bote.packet.dht.IndexPacket)1 StoreRequest (i2p.bote.packet.dht.StoreRequest)1 RelayPeerManager (i2p.bote.service.RelayPeerManager)1 BufferedWriter (java.io.BufferedWriter)1 ByteArrayInputStream (java.io.ByteArrayInputStream)1 FileWriter (java.io.FileWriter)1 ArrayList (java.util.ArrayList)1 AtomicLong (java.util.concurrent.atomic.AtomicLong)1 I2PSession (net.i2p.client.I2PSession)1 Destination (net.i2p.data.Destination)1 AuditScheduler (org.apache.geode.cache.util.AutoBalancer.AuditScheduler)1 CacheOperationFacade (org.apache.geode.cache.util.AutoBalancer.CacheOperationFacade)1 OOBAuditor (org.apache.geode.cache.util.AutoBalancer.OOBAuditor)1