Search in sources :

Example 1 with TestTransport

use of org.commonjava.maven.galley.testing.core.transport.TestTransport in project galley by Commonjava.

the class GalleyMavenFixture method initTestTransport.

public void initTestTransport() {
    testTransport = new TestTransport();
    mavenBuilder.withAdditionalTransport(testTransport);
}
Also used : TestTransport(org.commonjava.maven.galley.testing.core.transport.TestTransport)

Example 2 with TestTransport

use of org.commonjava.maven.galley.testing.core.transport.TestTransport in project galley by Commonjava.

the class TransferManagerImplTest method setup.

@Before
public void setup() {
    transport = new TestTransport();
    transportMgr = new TransportManagerImpl(transport);
    cacheProvider = new FileCacheProvider(temp.newFolder("cache"), new HashedLocationPathGenerator(), new NoOpFileEventManager(), new NoOpTransferDecorator(), true);
    nfc = new MemoryNotFoundCache();
    fileEvents = new NoOpFileEventManager();
    executor = Executors.newSingleThreadExecutor();
    TransportManagerConfig transportManagerConfig = new TransportManagerConfig();
    final DownloadHandler dh = new DownloadHandler(nfc, transportManagerConfig, executor);
    final UploadHandler uh = new UploadHandler(nfc, transportManagerConfig, executor);
    final ListingHandler lh = new ListingHandler(nfc);
    final ExistenceHandler eh = new ExistenceHandler(nfc);
    mgr = new TransferManagerImpl(transportMgr, cacheProvider, nfc, fileEvents, dh, uh, lh, eh, new SpecialPathManagerImpl(), Executors.newFixedThreadPool(2));
}
Also used : FileCacheProvider(org.commonjava.maven.galley.cache.FileCacheProvider) ListingHandler(org.commonjava.maven.galley.internal.xfer.ListingHandler) NoOpTransferDecorator(org.commonjava.maven.galley.io.NoOpTransferDecorator) TransferManagerImpl(org.commonjava.maven.galley.internal.TransferManagerImpl) TransportManagerImpl(org.commonjava.maven.galley.transport.TransportManagerImpl) HashedLocationPathGenerator(org.commonjava.maven.galley.io.HashedLocationPathGenerator) DownloadHandler(org.commonjava.maven.galley.internal.xfer.DownloadHandler) TransportManagerConfig(org.commonjava.maven.galley.config.TransportManagerConfig) MemoryNotFoundCache(org.commonjava.maven.galley.nfc.MemoryNotFoundCache) SpecialPathManagerImpl(org.commonjava.maven.galley.io.SpecialPathManagerImpl) NoOpFileEventManager(org.commonjava.maven.galley.event.NoOpFileEventManager) TestTransport(org.commonjava.maven.galley.testing.core.transport.TestTransport) UploadHandler(org.commonjava.maven.galley.internal.xfer.UploadHandler) ExistenceHandler(org.commonjava.maven.galley.internal.xfer.ExistenceHandler) Before(org.junit.Before)

Example 3 with TestTransport

use of org.commonjava.maven.galley.testing.core.transport.TestTransport in project galley by Commonjava.

the class CoreFixture method initTestTransport.

public void initTestTransport() {
    System.out.println("Initializing test transport directly");
    testTransport = new TestTransport();
    coreBuilder.withAdditionalTransport(testTransport);
}
Also used : TestTransport(org.commonjava.maven.galley.testing.core.transport.TestTransport)

Aggregations

TestTransport (org.commonjava.maven.galley.testing.core.transport.TestTransport)3 FileCacheProvider (org.commonjava.maven.galley.cache.FileCacheProvider)1 TransportManagerConfig (org.commonjava.maven.galley.config.TransportManagerConfig)1 NoOpFileEventManager (org.commonjava.maven.galley.event.NoOpFileEventManager)1 TransferManagerImpl (org.commonjava.maven.galley.internal.TransferManagerImpl)1 DownloadHandler (org.commonjava.maven.galley.internal.xfer.DownloadHandler)1 ExistenceHandler (org.commonjava.maven.galley.internal.xfer.ExistenceHandler)1 ListingHandler (org.commonjava.maven.galley.internal.xfer.ListingHandler)1 UploadHandler (org.commonjava.maven.galley.internal.xfer.UploadHandler)1 HashedLocationPathGenerator (org.commonjava.maven.galley.io.HashedLocationPathGenerator)1 NoOpTransferDecorator (org.commonjava.maven.galley.io.NoOpTransferDecorator)1 SpecialPathManagerImpl (org.commonjava.maven.galley.io.SpecialPathManagerImpl)1 MemoryNotFoundCache (org.commonjava.maven.galley.nfc.MemoryNotFoundCache)1 TransportManagerImpl (org.commonjava.maven.galley.transport.TransportManagerImpl)1 Before (org.junit.Before)1