diff --git a/spring-rest/pom.xml b/spring-rest/pom.xml index 0c0d6219dd..5340f8b437 100644 --- a/spring-rest/pom.xml +++ b/spring-rest/pom.xml @@ -182,7 +182,6 @@ org.apache.maven.plugins maven-compiler-plugin - ${maven-compiler-plugin.version} 1.8 1.8 @@ -192,13 +191,11 @@ org.apache.maven.plugins maven-war-plugin - ${maven-war-plugin.version} org.apache.maven.plugins maven-surefire-plugin - ${maven-surefire-plugin.version} @@ -234,6 +231,61 @@ + + + live + + + + org.codehaus.cargo + cargo-maven2-plugin + + + start-server + pre-integration-test + + start + + + + stop-server + post-integration-test + + stop + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + integration-test + + test + + + + none + + + **/*LiveTest.java + + + cargo + + + + + + + + + + + diff --git a/spring-rest/src/test/java/org/baeldung/web/test/RequestMappingLiveTest.java b/spring-rest/src/test/java/org/baeldung/web/test/RequestMappingLiveTest.java index fd349f1e44..3155b5cda9 100644 --- a/spring-rest/src/test/java/org/baeldung/web/test/RequestMappingLiveTest.java +++ b/spring-rest/src/test/java/org/baeldung/web/test/RequestMappingLiveTest.java @@ -7,7 +7,7 @@ import org.junit.Test; import com.jayway.restassured.RestAssured; public class RequestMappingLiveTest { - private static String BASE_URI = "http://localhost:8080/spring-rest/ex/"; + private static String BASE_URI = "http://localhost:8082/spring-rest/ex/"; @Test public void givenSimplePath_whenGetFoos_thenOk() { diff --git a/spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersIntegrationTestsCase.java b/spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersLiveTest.java similarity index 97% rename from spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersIntegrationTestsCase.java rename to spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersLiveTest.java index 1dfe509c09..7f250653ab 100644 --- a/spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersIntegrationTestsCase.java +++ b/spring-rest/src/test/java/org/baeldung/web/test/SpringHttpMessageConvertersLiveTest.java @@ -21,9 +21,9 @@ import org.springframework.web.client.RestTemplate; /** * Integration Test class. Tests methods hits the server's rest services. */ -public class SpringHttpMessageConvertersIntegrationTestsCase { +public class SpringHttpMessageConvertersLiveTest { - private static String BASE_URI = "http://localhost:8080/spring-rest/"; + private static String BASE_URI = "http://localhost:8082/spring-rest/"; /** * Without specifying Accept Header, uses the default response from the