org.sonatype.goodies.httpfixture.server.fluent.Server Java Examples
The following examples show how to use
org.sonatype.goodies.httpfixture.server.fluent.Server.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ComposerProxyIT.java From nexus-repository-composer with Eclipse Public License 1.0 | 6 votes |
@Before public void setup() throws Exception { server = Server.withPort(0) .serve("/" + FILE_PACKAGES) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_PACKAGES))) .serve("/" + VALID_LIST_URL) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_LIST))) .serve("/" + VALID_PROVIDER_URL) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_PROVIDER))) .serve("/" + VALID_ZIPBALL_URL) .withBehaviours(Behaviours.file(testData.resolveFile(ZIPBALL_FILE_NAME))) .start(); proxyRepo = repos.createComposerProxy("composer-test-proxy", server.getUrl().toExternalForm()); proxyClient = composerClient(proxyRepo); }
Example #2
Source File: HelmRestoreBlobIT.java From nexus-repository-helm with Eclipse Public License 1.0 | 6 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); hostedRepository = repos.createHelmHosted(HOSTED_REPO_NAME); hostedClient = createHelmClient(hostedRepository); proxyServer = Server.withPort(0) .serve("/" + MONGO_PATH_FULL_728_TARGZ) .withBehaviours(file(testData.resolveFile(MONGO_PKG_FILE_NAME_728_TGZ))) .start(); proxyRepository = repos.createHelmProxy(PROXY_REPO_NAME, "http://localhost:" + proxyServer.getPort() + "/"); proxyClient = createHelmClient(proxyRepository); assertThat(hostedClient.put(MONGO_PATH_FULL_728_TARGZ, fileToHttpEntity(MONGO_PKG_FILE_NAME_728_TGZ)).getStatusLine().getStatusCode(), is(HttpStatus.OK)); assertThat(proxyClient.fetch(MONGO_PATH_FULL_728_TARGZ, CONTENT_TYPE_TGZ).getStatusLine().getStatusCode(), is(HttpStatus.OK)); }
Example #3
Source File: RRestoreBlobIT.java From nexus-repository-r with Eclipse Public License 1.0 | 6 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); hostedRepository = repos.createRHosted(HOSTED_REPO_NAME); hostedClient = createRClient(hostedRepository); proxyServer = Server.withPort(0) .serve("/" + AGRICOLAE_131_TARGZ.fullPath) .withBehaviours(file(testData.resolveFile(AGRICOLAE_131_TARGZ.filename))) .start(); proxyRepository = repos.createRProxy(PROXY_REPO_NAME, "http://localhost:" + proxyServer.getPort() + "/"); proxyClient = createRClient(proxyRepository); assertThat(hostedClient.put(AGRICOLAE_131_TARGZ.fullPath, fileToHttpEntity(AGRICOLAE_131_TARGZ.filename)).getStatusLine().getStatusCode(), is(HttpStatus.OK)); assertThat(proxyClient.fetch(AGRICOLAE_131_TARGZ.fullPath).getStatusLine().getStatusCode(), is(HttpStatus.OK)); }
Example #4
Source File: RProxyIT.java From nexus-repository-r with Eclipse Public License 1.0 | 6 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); server = Server.withPort(0) .serve("/*") .withBehaviours(error(NOT_FOUND)) .serve("/" + AGRICOLAE_131_TGZ.fullPath) .withBehaviours(file(testData.resolveFile(AGRICOLAE_131_TGZ.filename))) .serve("/" + AGRICOLAE_131_TARGZ.fullPath) .withBehaviours(file(testData.resolveFile(AGRICOLAE_131_TARGZ.filename))) .serve("/" + AGRICOLAE_131_XXX.fullPath) .withBehaviours(file(testData.resolveFile(AGRICOLAE_131_XXX.filename))) .serve("/" + PACKAGES_SRC_GZ.fullPath) .withBehaviours(file(testData.resolveFile(PACKAGES_SRC_GZ.filename))) .serve("/" + PACKAGES_RDS.fullPath) .withBehaviours(file(testData.resolveFile(PACKAGES_RDS.filename))) .serve("/" + ARCHIVE_RDS.fullPath) .withBehaviours(file(testData.resolveFile(ARCHIVE_RDS.filename))) .start(); repository = repos.createRProxy("r-proxy-test", server.getUrl().toExternalForm()); client = rClient(repository); }
Example #5
Source File: RGroupIT.java From nexus-repository-r with Eclipse Public License 1.0 | 6 votes |
@Before public void setUp() throws Exception { ThreadContext.bind(FakeAlmightySubject.forUserId("disabled-security")); remote = Server.withPort(0) .serve("/*").withBehaviours(error(NOT_FOUND)) .serve("/" + AGRICOLAE_121_TARGZ.fullPath) .withBehaviours(file(testData.resolveFile(AGRICOLAE_121_TARGZ.filename))) .start(); repoProxy = repos.createRProxy(testName.getMethodName() + "-proxy", remote.getUrl().toExternalForm()); repoHosted = repos.createRHosted(testName.getMethodName() + "-hosted"); repoGroup = repos.createRGroup(testName.getMethodName() + "-group", repoHosted.getName(), repoProxy.getName()); hostedClient = createRClient(repoHosted); groupClient = createRClient(repoGroup); assertThat(status(hostedClient.putAndClose(AGRICOLAE_131_TARGZ.fullPath, fileToHttpEntity(AGRICOLAE_131_TARGZ.filename))), is(OK)); }
Example #6
Source File: CleanupTaskConanProxyIT.java From nexus-repository-conan with Eclipse Public License 1.0 | 6 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); testData.addDirectory(NexusPaxExamSupport.resolveBaseFile("target/it-resources/conan")); testData.addDirectory(NexusPaxExamSupport.resolveBaseFile("target/test-classes/conan")); server = Server.withPort(0) .serve("/" + JSON_FOR_MODERN_CPP_URL) .withBehaviours(Behaviours.file(testData.resolveFile(DOWNLOAD_URLS_FILE_NAME))) .serve("/" + LIB_URL) .withBehaviours(Behaviours.file(testData.resolveFile(LIB_DOWNLOAD_URLS_FILE_NAME))) .start(); proxyRepo = repos.createConanProxy(testName.getMethodName(), server.getUrl().toExternalForm()); URL repositoryUrl = repositoryBaseUrl(proxyRepo); proxyClient = new ConanClient( clientBuilder(repositoryUrl).build(), clientContext(), repositoryUrl.toURI() ); proxyClient.get(JSON_FOR_MODERN_CPP_URL); }
Example #7
Source File: CleanupTaskP2ProxyIT.java From nexus-repository-p2 with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); testData.addDirectory(NexusPaxExamSupport.resolveBaseFile("target/test-classes/p2")); server = Server.withPort(0) .serve("/" + VALID_PACKAGE_URL) .withBehaviours(Behaviours.file(testData.resolveFile(PACKAGE_NAME))) .serve("/" + VALID_HELP_PACKAGE_URL) .withBehaviours(Behaviours.file(testData.resolveFile(HELP_PACKAGE_NAME))) .start(); proxyRepo = repos.createP2Proxy(testName.getMethodName(), server.getUrl().toExternalForm()); proxyClient = p2Client(proxyRepo); deployArtifacts(VALID_HELP_PACKAGE_URL); }
Example #8
Source File: RawProxyIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
private void responseViaProxyProduces(final int upstreamStatus, final int downstreamStatus) throws Exception { Server server = Server.withPort(0).serve("/*").withBehaviours(Behaviours.error(upstreamStatus)).start(); try { proxyClient = rawClient(repos.createRawProxy("raw-test-proxy-" + upstreamStatus + "-" + downstreamStatus, server.getUrl().toExternalForm())); assertThat(status(proxyClient.get(TEST_PATH)), is(downstreamStatus)); } finally { server.stop(); } }
Example #9
Source File: RawProxyIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
private void responseViaGroupProduces(final int upstreamStatus, final int downstreamStatus) throws Exception { Server server = Server.withPort(0).serve("/*").withBehaviours(Behaviours.error(upstreamStatus)).start(); try { Repository proxy = repos.createRawProxy("raw-test-proxy-" + upstreamStatus + "-" + downstreamStatus, server.getUrl().toExternalForm()); Repository group = repos.createRawGroup("raw-test-group-" + upstreamStatus + "-" + downstreamStatus, proxy.getName()); proxyClient = rawClient(group); assertThat(status(proxyClient.get(TEST_PATH)), is(downstreamStatus)); } finally { server.stop(); } }
Example #10
Source File: RawProxyIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
@Test public void retrieveRawWhenRemoteOffline() throws Exception { Server server = Server.withPort(0).serve("/*") .withBehaviours(content("Response")) .start(); try { proxyClient = rawClient(repos.createRawProxy("raw-test-proxy-offline", server.getUrl().toExternalForm())); proxyClient.get(TEST_PATH); } finally { server.stop(); } assertThat(status(proxyClient.get(TEST_PATH)), is(200)); }
Example #11
Source File: RawProxyOfHostedIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
private void responseViaGroupProduces(final int upstreamStatus, final int downstreamStatus) throws Exception { Server server = Server.withPort(0).serve("/*").withBehaviours(Behaviours.error(upstreamStatus)).start(); try { Repository proxy = repos.createRawProxy("raw-test-proxy-" + upstreamStatus + "-" + downstreamStatus, server.getUrl().toExternalForm()); Repository group = repos.createRawGroup("raw-test-group-" + upstreamStatus + "-" + downstreamStatus, proxy.getName()); proxyClient = rawClient(group); assertThat(status(proxyClient.get(TEST_PATH)), is(downstreamStatus)); } finally { server.stop(); } }
Example #12
Source File: RawProxyOfHostedIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
@Test public void retrieveRawWhenRemoteOffline() throws Exception { Server server = Server.withPort(0).serve("/*") .withBehaviours(content("Response")) .start(); try { proxyClient = rawClient(repos.createRawProxy("raw-test-proxy-offline", server.getUrl().toExternalForm())); proxyClient.get(TEST_PATH); } finally { server.stop(); } assertThat(status(proxyClient.get(TEST_PATH)), is(200)); }
Example #13
Source File: RawProxyOfHostedIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
private void responseViaProxyProduces(final int upstreamStatus, final int downstreamStatus) throws Exception { Server server = Server.withPort(0).serve("/*").withBehaviours(Behaviours.error(upstreamStatus)).start(); try { proxyClient = rawClient(repos.createRawProxy("raw-test-proxy-" + upstreamStatus + "-" + downstreamStatus, server.getUrl().toExternalForm())); assertThat(status(proxyClient.get(TEST_PATH)), is(downstreamStatus)); } finally { server.stop(); } }
Example #14
Source File: RawRestoreBlobIT.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { hostedRepository = repos.createRawHosted(HOSTED_REPO_NAME); hostedClient = rawClient(hostedRepository); proxyServer = Server.withPort(0).start(); proxyServer.serve("/" + TEST_CONTENT).withBehaviours(resolveFile(TEST_CONTENT)); proxyRepository = repos.createRawProxy(PROXY_REPO_NAME, "http://localhost:" + proxyServer.getPort() + "/"); proxyClient = rawClient(proxyRepository); File testFile = resolveTestFile(TEST_CONTENT); assertThat(hostedClient.put(TEST_CONTENT, TEXT_PLAIN, testFile), is(HttpStatus.CREATED)); assertThat(proxyClient.get(TEST_CONTENT).getStatusLine().getStatusCode(), is(HttpStatus.OK)); }
Example #15
Source File: PyPiPackageListRetrieverTest.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
@Before public void setUp() throws Exception { server = Server.withPort(0) .serve("/*").withBehaviours(error(200)) .serve("/" + REPOSITORY_NAME + "/simple/").withBehaviours(content(INDEX, TEXT_HTML)) .serve("/" + REPOSITORY_NAME + "/simple/test1/").withBehaviours(content(PACKAGE_INDEX_1, TEXT_HTML)) .serve("/" + REPOSITORY_NAME + "/simple/test2/").withBehaviours(content(PACKAGE_INDEX_2, TEXT_HTML)); server.start(); }
Example #16
Source File: HttpValidationITRule.java From nexus-public with Eclipse Public License 1.0 | 5 votes |
public HttpValidationITRule(PortRegistry portRegistry, ValidatingBehaviour upstreamValidatingBehavior, Provider<HttpClientManager> httpClientManagerProvider) { this.portRegistry = checkNotNull(portRegistry); this.upstreamValidatingBehaviour = checkNotNull(upstreamValidatingBehavior); this.configTestHelper = new HttpConfigurationTestHelper(checkNotNull(httpClientManagerProvider)); // Initialize the upstream server with basic validation behavior this.upstreamServer = Server.server().port(portRegistry.reservePort()).serve("") .withBehaviours(upstreamValidatingBehavior); }
Example #17
Source File: ConanProxyIT.java From nexus-repository-conan with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); server = Server.withPort(CONAN_REMOTE_PORT) .serve("/" + PATH_DOWNLOAD_URLS) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_DOWNLOAD_URLS))) .serve("/" + PATH_DIGEST) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_DIGEST))) .serve("/" + PATH_DOWNLOAD_URLS_WITHOUT_PACKAGES) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_DOWNLOAD_URLS_NON_PACKAGE))) .serve("/" + LIB_WITH_WRONG_CONANINFO_HASH_DOWNLOAD_URLS_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(LIB_WITH_WRONG_CONANINFO_HASH_DOWNLOAD_URLS_FILE_NAME))) .serve("/" + PATH_TGZ_PACKAGE) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_PACKAGE))) .serve("/" + PATH_INFO) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_INFO))) .serve("/" + LIB_WITH_WRONG_CONANINFO_HASH_CONANINFO_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_INFO))) .serve("/" + PATH_MANIFEST) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_MANIFEST))) .serve("/" + LIB_WITH_WRONG_CONANINFO_HASH_CONANMANIFEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(LIB_WITH_WRONG_CONANINFO_HASH_CONANMANIFEST_FILE_NAME))) .start(); proxyRepo = repos.createConanProxy(NXRM_CONAN_PROXY_REPO_NAME, server.getUrl().toExternalForm()); proxyClient = conanClient(proxyRepo); proxyClient.getHttpResponse(PATH_DOWNLOAD_URLS); }
Example #18
Source File: ConanRoutingRuleIT.java From nexus-repository-conan with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { server = Server.withPort(0).serve("/" + JSON_FOR_MODERN_CPP_URL) .withBehaviours(Behaviours.file(testData.resolveFile(DOWNLOAD_URLS_FILE_NAME))) .serve("/" + JSON_FOR_MODERN_CPP_BLOCKED_URL) .withBehaviours(Behaviours.file(testData.resolveFile(DOWNLOAD_URLS_FILE_NAME))) .start(); proxyRepo = repos.createConanProxy(testName.getMethodName(), server.getUrl().toExternalForm()); proxyClient = conanClient(proxyRepo); EntityId routingRuleId = createBlockedRoutingRule("conan-rule", BLOCKED_VENDOR_REGEX); attachRuleToRepository(proxyRepo, routingRuleId); }
Example #19
Source File: ConanProxySearchIT.java From nexus-repository-conan with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); server = Server .withPort(CONAN_REMOTE_PORT) // we should make sure that proxy will not use download_urls .serve("/" + PATH_DOWNLOAD_URLS) .withBehaviours(Behaviours.error(501)) .serve("/" + PATH_PATTERN_SEARCH) .withBehaviours(Behaviours.content(MOCK_PATTERN_SEARCH_REMOTE_RESPONSE, ContentTypes.APPLICATION_JSON)) .serve("/" + PATH_SEARCH) .withBehaviours(Behaviours.content(MOCK_SEARCH_REMOTE_RESPONSE, ContentTypes.APPLICATION_JSON)) .serve("/" + PATH_DIGEST) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_DIGEST))) .serve("/" + PATH_MANIFEST) .withBehaviours(Behaviours.file(testData.resolveFile(FILE_MANIFEST))) .start(); proxyRepo = repos.createConanProxy(NXRM_CONAN_PROXY_REPO_NAME, server.getUrl().toExternalForm()); proxyClient = conanClient(proxyRepo); }
Example #20
Source File: HelmProxyIT.java From nexus-repository-helm with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); server = Server.withPort(0) .serve("/*").withBehaviours(error(200)) .serve("/" + MONGO_PKG_FILE_NAME_600_TGZ).withBehaviours(file(testData.resolveFile(MONGO_PKG_FILE_NAME_600_TGZ))) .serve("/" + YAML_FILE_NAME).withBehaviours(file(testData.resolveFile(YAML_FILE_NAME))) .start(); repository = repos.createHelmProxy("helm-proxy-test", server.getUrl().toExternalForm()); client = helmClient(repository); }
Example #21
Source File: HelmContentProxyIT.java From nexus-repository-helm with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); server = Server.withPort(0) .serve("/*").withBehaviours(error(200)) .serve("/" + MONGO_PKG_FILE_NAME_600_TGZ) .withBehaviours(file(testData.resolveFile(MONGO_PKG_FILE_NAME_600_TGZ))) .serve("/" + YAML_FILE_NAME).withBehaviours(file(testData.resolveFile(YAML_FILE_NAME))) .start(); repository = repos.createHelmProxy("helm-proxy-test", server.getUrl().toExternalForm()); client = helmClient(repository); }
Example #22
Source File: P2RestoreBlobIT.java From nexus-repository-p2 with Eclipse Public License 1.0 | 5 votes |
@Before public void setup() throws Exception { BaseUrlHolder.set(this.nexusUrl.toString()); proxyServer = Server.withPort(0) .serve("/" + VALID_PACKAGE_URL) .withBehaviours(Behaviours.file(testData.resolveFile(PACKAGE_NAME))) .start(); proxyRepository = repos.createP2Proxy(P2ProxyRecipe.NAME, "http://localhost:" + proxyServer.getPort() + "/"); proxyClient = p2Client(proxyRepository); assertThat(proxyClient.get(VALID_PACKAGE_URL).getStatusLine().getStatusCode(), is(HttpStatus.OK)); }
Example #23
Source File: HttpValidationITRule.java From nexus-public with Eclipse Public License 1.0 | 4 votes |
public Server getUpstreamServer() { return upstreamServer; }
Example #24
Source File: NpmUpstream.java From nexus-public with Eclipse Public License 1.0 | 4 votes |
@Override public void doStart() throws Exception { remote = Server.withPort(0).start(); }
Example #25
Source File: FineGrainedDispatch.java From nexus-public with Eclipse Public License 1.0 | 4 votes |
public FineGrainedDispatch(final Server proxyServer, final String root) { this.proxyServer = proxyServer; proxyServer.serve(root).withServlet(this); }
Example #26
Source File: RRoutingRuleIT.java From nexus-repository-r with Eclipse Public License 1.0 | 4 votes |
@Before public void startup() throws Exception { proxyServer = Server.withPort(0).start(); }
Example #27
Source File: HelmRoutingRuleIT.java From nexus-repository-helm with Eclipse Public License 1.0 | 4 votes |
@Before public void startup() throws Exception { proxyServer = Server.withPort(0).start(); }
Example #28
Source File: P2RoutingRuleIT.java From nexus-repository-p2 with Eclipse Public License 1.0 | 4 votes |
@Before public void startup() throws Exception { proxyServer = Server.withPort(0).start(); }
Example #29
Source File: P2ProxyIT.java From nexus-repository-p2 with Eclipse Public License 1.0 | 4 votes |
@Before public void setup() throws Exception { server = Server.withPort(0) .serve("/" + VALID_PACKAGE_URL) .withBehaviours(Behaviours.file(testData.resolveFile(PACKAGE_NAME))) .serve("/" + ARTIFACT_JAR) .withBehaviours(Behaviours.file(testData.resolveFile(ARTIFACT_JAR))) .serve("/" + ARTIFACT_XML_TEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(ARTIFACT_XML))) .serve("/" + ARTIFACT_XML_XZ_TEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(ARTIFACT_XML_XZ))) .serve("/" + P2_INDEX) .withBehaviours(Behaviours.file(testData.resolveFile(P2_INDEX))) .serve("/folder/" + P2_INDEX) .withBehaviours(Behaviours.file(testData.resolveFile(P2_INDEX))) .serve("/" + COMPOSITE_ARTIFACTS_JAR) .withBehaviours(Behaviours.file(testData.resolveFile(COMPOSITE_ARTIFACTS_JAR))) .serve("/" + COMPOSITE_ARTIFACTS_XML) .withBehaviours(Behaviours.file(testData.resolveFile(COMPOSITE_ARTIFACTS_XML))) .serve("/" + COMPOSITE_CONTENT_JAR) .withBehaviours(Behaviours.file(testData.resolveFile(COMPOSITE_CONTENT_JAR))) .serve("/" + COMPOSITE_CONTENT_XML) .withBehaviours(Behaviours.file(testData.resolveFile(COMPOSITE_CONTENT_XML))) .serve("/" + CONTENT_XML_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(CONTENT_XML))) .serve("/" + CONTENT_JAR_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(CONTENT_JAR))) .serve("/" + CONTENT_XML_XZ_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(CONTENT_XML_XZ))) .serve("/" + BINARY_TEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(BINARY))) .serve("/" + PLUGIN_TEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(PLUGIN))) .serve("/" + FEATURE_TEST_PATH) .withBehaviours(Behaviours.file(testData.resolveFile(FEATURE))) .serve("/" + ACCELEO_COMPONENT_NAME + ACCELEO_COMPONENT_VERSION + "/features/" + ACCELEO_FEATURE_JAR) .withBehaviours(Behaviours.file(testData.resolveFile(ACCELEO_FEATURE_JAR))) .serve("/" + ACCELEO_COMPONENT_NAME + ACCELEO_COMPONENT_VERSION + "/plugins/" + ACCELEO_PLUGIN_GZ) .withBehaviours(Behaviours.file(testData.resolveFile(ACCELEO_PLUGIN_GZ))) .start(); proxyRepo = repos.createP2Proxy("p2-test-proxy", server.getUrl().toExternalForm()); proxyClient = p2Client(proxyRepo); }
Example #30
Source File: HttpClientManagerImplIT.java From nexus-public with Eclipse Public License 1.0 | 4 votes |
private static Server createHeaderValidatingServerSSL() { return Server.server() .withKeystore(HttpClientManagerImplIT.class.getClassLoader().getResource("testkeystore").getFile(), "password") .serve("").withBehaviours(httpsValidatingBehaviour); }