use of org.commonjava.maven.galley.auth.MemoryPasswordManager in project indy by Commonjava.
the class ArtifactStoreValidatorTest method setup.
@Before
public void setup() throws Exception {
cacheDir = temp.newFolder();
galley = new GalleyCoreBuilder(new FileCacheProviderFactory(cacheDir)).withEnabledTransports(new HttpClientTransport(new HttpImpl(new MemoryPasswordManager()))).build();
validator = new ArtifactStoreValidator(galley.getTransferManager());
}
use of org.commonjava.maven.galley.auth.MemoryPasswordManager in project indy by Commonjava.
the class ImpliedRepositoryDetectorTest method setup.
@Before
public void setup() throws Throwable {
fixture = new GalleyMavenFixture(temp);
fixture.initGalley();
fixture.withEnabledTransports(new HttpClientTransport(new HttpImpl(new MemoryPasswordManager())));
fixture.before();
storeManager = new MemoryStoreDataManager(true);
metadataManager = new ImpliedRepoMetadataManager(new IndyObjectMapper(true));
final ImpliedRepoConfig config = new ImpliedRepoConfig();
config.setEnabled(true);
config.addEnabledGroupNamePattern(".*");
File rootDir = temp.newFolder("indy.root");
final DataFileManager dataFiles = new DataFileManager(rootDir, new DataFileEventManager());
validator = new ArtifactStoreValidator(fixture.getTransferManager());
final IndyObjectMapper mapper = new IndyObjectMapper(Collections.emptySet());
ScriptEngine engine = new ScriptEngine(dataFiles);
detector = new TestImpliedRepositoryDetector(fixture.getPomReader(), storeManager, metadataManager, validator, engine, config, mapper);
summary = new ChangeSummary(ChangeSummary.SYSTEM_USER, "test setup");
RemoteRepository remote = new RemoteRepository("test", "http://www.foo.com/repo");
Group group = new Group("group", remote.getKey());
storeManager.storeArtifactStore(remote, summary, false, true, new EventMetadata());
storeManager.storeArtifactStore(group, summary, false, true, new EventMetadata());
server.expect("HEAD", server.formatUrl("/repo/"), 200, "");
}
use of org.commonjava.maven.galley.auth.MemoryPasswordManager in project galley by Commonjava.
the class EmbeddableCDIProducer method postConstruct.
@PostConstruct
public void postConstruct() {
fileEventManager = new NoOpFileEventManager();
transferDecorator = new NoOpTransferDecorator();
pathGenerator = new HashedLocationPathGenerator();
nfc = new MemoryNotFoundCache();
// locationExpander = new NoOpLocationExpander();
// locationResolver = new SimpleUrlLocationResolver( locationExpander, transportManager );
transportManagerConfig = new TransportManagerConfig();
passwordManager = new MemoryPasswordManager();
http = new HttpImpl(passwordManager);
objectMapper = new ObjectMapper();
objectMapper.registerModules(new ProjectVersionRefSerializerModule());
pluginDefaults = new StandardMaven350PluginDefaults();
pluginImplications = new StandardMavenPluginImplications(xml);
}
Aggregations