diff --git a/httpclient/src/test/java/org/baeldung/httpclient/HttpClientConnectionManagementTest.java b/httpclient/src/test/java/org/baeldung/httpclient/HttpClientConnectionManagementTest.java index a761338738..3a54dfb9ec 100644 --- a/httpclient/src/test/java/org/baeldung/httpclient/HttpClientConnectionManagementTest.java +++ b/httpclient/src/test/java/org/baeldung/httpclient/HttpClientConnectionManagementTest.java @@ -1,5 +1,22 @@ package org.baeldung.httpclient; +import org.apache.http.HttpHost; +import org.apache.http.client.protocol.HttpClientContext; +import org.apache.http.conn.ConnectionRequest; +import org.apache.http.conn.routing.HttpRoute; +import org.apache.http.impl.conn.BasicHttpClientConnectionManager; +import org.junit.Test; + public class HttpClientConnectionManagementTest { - // + + // tests + + @Test + public final void whenLowLevelConnectionIsEstablished_thenNoExceptions() { + final HttpClientContext context = HttpClientContext.create(); + final BasicHttpClientConnectionManager connManager = new BasicHttpClientConnectionManager(); + final HttpRoute route = new HttpRoute(new HttpHost("localhost", 80)); + final ConnectionRequest connRequest = connManager.requestConnection(route, null); + } + } diff --git a/spring-security-rest-full/src/main/java/org/baeldung/spring/PersistenceConfig.java b/spring-security-rest-full/src/main/java/org/baeldung/spring/PersistenceConfig.java index 160650afaf..dad4808a56 100644 --- a/spring-security-rest-full/src/main/java/org/baeldung/spring/PersistenceConfig.java +++ b/spring-security-rest-full/src/main/java/org/baeldung/spring/PersistenceConfig.java @@ -23,7 +23,7 @@ import com.google.common.base.Preconditions; @Configuration @EnableTransactionManagement -@PropertySource({ "classpath:persistence-mysql.properties" }) +@PropertySource({ "classpath:persistence-${envTarget:mysql}.properties" }) @ComponentScan({ "org.baeldung.persistence" }) // @ImportResource("classpath*:springDataPersistenceConfig.xml") @EnableJpaRepositories(basePackages = "org.baeldung.persistence.dao")