Java-2394 Create default and integration profile for JDK-9 and above modules
This commit is contained in:
parent
9541b56c5e
commit
ae5ee571b9
|
@ -7,7 +7,7 @@ import junit.framework.TestSuite;
|
||||||
/**
|
/**
|
||||||
* Unit test for simple App.
|
* Unit test for simple App.
|
||||||
*/
|
*/
|
||||||
public class AppTest
|
public class AppUnitTest
|
||||||
extends TestCase
|
extends TestCase
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
|
@ -15,7 +15,7 @@ public class AppTest
|
||||||
*
|
*
|
||||||
* @param testName name of the test case
|
* @param testName name of the test case
|
||||||
*/
|
*/
|
||||||
public AppTest( String testName )
|
public AppUnitTest(String testName )
|
||||||
{
|
{
|
||||||
super( testName );
|
super( testName );
|
||||||
}
|
}
|
||||||
|
@ -25,7 +25,7 @@ public class AppTest
|
||||||
*/
|
*/
|
||||||
public static Test suite()
|
public static Test suite()
|
||||||
{
|
{
|
||||||
return new TestSuite( AppTest.class );
|
return new TestSuite( AppUnitTest.class );
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
|
@ -107,7 +107,7 @@
|
||||||
<uberjar.name>benchmarks</uberjar.name>
|
<uberjar.name>benchmarks</uberjar.name>
|
||||||
<jmh.version>1.22</jmh.version>
|
<jmh.version>1.22</jmh.version>
|
||||||
<eclipse.collections.version>10.0.0</eclipse.collections.version>
|
<eclipse.collections.version>10.0.0</eclipse.collections.version>
|
||||||
<shade.plugin.version>10.0.0</shade.plugin.version>
|
<shade.plugin.version>3.2.4</shade.plugin.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -5,7 +5,7 @@ import static org.hamcrest.MatcherAssert.assertThat;
|
||||||
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class StringAPITest {
|
public class StringAPIUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void whenPositiveArgument_thenReturnIndentedString() {
|
public void whenPositiveArgument_thenReturnIndentedString() {
|
|
@ -7,7 +7,7 @@ import static org.junit.Assert.assertTrue;
|
||||||
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class PersonTest {
|
public class PersonUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenSameNameAndAddress_whenEquals_thenPersonsEqual() {
|
public void givenSameNameAndAddress_whenEquals_thenPersonsEqual() {
|
|
@ -44,6 +44,16 @@
|
||||||
<artifactId>commons-collections4</artifactId>
|
<artifactId>commons-collections4</artifactId>
|
||||||
<version>${commons-collections4.version}</version>
|
<version>${commons-collections4.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.commons</groupId>
|
||||||
|
<artifactId>commons-lang3</artifactId>
|
||||||
|
<version>3.11</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>commons-io</groupId>
|
||||||
|
<artifactId>commons-io</artifactId>
|
||||||
|
<version>2.7</version>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
@ -77,6 +87,7 @@
|
||||||
<maven.compiler.target>1.9</maven.compiler.target>
|
<maven.compiler.target>1.9</maven.compiler.target>
|
||||||
<guava.version>25.1-jre</guava.version>
|
<guava.version>25.1-jre</guava.version>
|
||||||
<commons-collections4.version>4.1</commons-collections4.version>
|
<commons-collections4.version>4.1</commons-collections4.version>
|
||||||
|
<commons-collections3.version>3.2.2</commons-collections3.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -17,7 +17,7 @@ import org.junit.Test;
|
||||||
/**
|
/**
|
||||||
* Test case for the {@link MethodHandles} API
|
* Test case for the {@link MethodHandles} API
|
||||||
*/
|
*/
|
||||||
public class MethodHandlesTest {
|
public class MethodHandlesUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenConcatMethodHandle_whenInvoked_thenCorrectlyConcatenated() throws Throwable {
|
public void givenConcatMethodHandle_whenInvoked_thenCorrectlyConcatenated() throws Throwable {
|
|
@ -6,7 +6,7 @@ import org.junit.jupiter.api.Test;
|
||||||
import java.sql.Timestamp;
|
import java.sql.Timestamp;
|
||||||
import java.time.format.DateTimeFormatter;
|
import java.time.format.DateTimeFormatter;
|
||||||
|
|
||||||
public class TimestampToStringConverterTest {
|
public class TimestampToStringConverterUnitTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void givenDatePattern_whenFormatting_thenResultingStringIsCorrect() {
|
public void givenDatePattern_whenFormatting_thenResultingStringIsCorrect() {
|
|
@ -17,7 +17,7 @@
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.baeldung.servicemodule</groupId>
|
<groupId>com.baeldung.servicemodule</groupId>
|
||||||
<artifactId>servicemodule</artifactId>
|
<artifactId>servicemodule1</artifactId>
|
||||||
<version>${servicemodule.version}</version>
|
<version>${servicemodule.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<artifactId>servicemodule</artifactId>
|
<groupId>com.baeldung.servicemodule</groupId>
|
||||||
|
<artifactId>servicemodule1</artifactId>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.baeldung.servicemodule</groupId>
|
<groupId>com.baeldung.servicemodule</groupId>
|
||||||
<artifactId>servicemodule</artifactId>
|
<artifactId>servicemodule2</artifactId>
|
||||||
<version>${servicemodule.version}</version>
|
<version>${servicemodule.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<artifactId>servicemodule</artifactId>
|
<groupId>com.baeldung.servicemodule</groupId>
|
||||||
|
<artifactId>servicemodule2</artifactId>
|
||||||
<version>1.0</version>
|
<version>1.0</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
|
|
|
@ -4,7 +4,7 @@ import static org.junit.Assert.assertTrue;
|
||||||
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class CurrentDirectoryFetcherTest {
|
public class CurrentDirectoryFetcherUnitTest {
|
||||||
|
|
||||||
private static final String CURRENT_DIR = "core-java-os";
|
private static final String CURRENT_DIR = "core-java-os";
|
||||||
|
|
|
@ -20,6 +20,10 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>${maven.compiler.source}</source>
|
||||||
|
<target>${maven.compiler.target}</target>
|
||||||
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
|
@ -20,6 +20,10 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>${maven.compiler.source}</source>
|
||||||
|
<target>${maven.compiler.target}</target>
|
||||||
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
|
@ -38,6 +38,10 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>${maven.compiler.source}</source>
|
||||||
|
<target>${maven.compiler.target}</target>
|
||||||
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
|
@ -33,6 +33,10 @@
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>${maven.compiler.source}</source>
|
||||||
|
<target>${maven.compiler.target}</target>
|
||||||
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
|
@ -18,20 +18,9 @@
|
||||||
|
|
||||||
<modules>
|
<modules>
|
||||||
<module>core-java</module>
|
<module>core-java</module>
|
||||||
<!-- <module>core-java-10</module> --> <!-- We haven't upgraded to java 10. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-11</module> --> <!-- We haven't upgraded to java 11. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-12</module> --> <!-- We haven't upgraded to java 12. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-13</module> --> <!-- We haven't upgraded to java 12. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-14</module> --> <!-- We haven't upgraded to java 14.-->
|
|
||||||
<module>core-java-8</module>
|
<module>core-java-8</module>
|
||||||
<module>core-java-8-2</module>
|
<module>core-java-8-2</module>
|
||||||
|
|
||||||
<!-- <module>core-java-9</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-9-improvements</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-9-jigsaw</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-9-new-features</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<!-- <module>core-java-9-streams</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
|
|
||||||
<module>core-java-annotations</module>
|
<module>core-java-annotations</module>
|
||||||
|
|
||||||
<module>core-java-arrays-sorting</module>
|
<module>core-java-arrays-sorting</module>
|
||||||
|
@ -51,7 +40,6 @@
|
||||||
<module>core-java-collections-maps</module>
|
<module>core-java-collections-maps</module>
|
||||||
<module>core-java-collections-maps-2</module>
|
<module>core-java-collections-maps-2</module>
|
||||||
<module>core-java-collections-maps-3</module>
|
<module>core-java-collections-maps-3</module>
|
||||||
<!-- <module>core-java-collections-set</module> --> <!-- We haven't upgraded to java 11. Fixing in BAEL-10841 -->
|
|
||||||
|
|
||||||
<module>core-java-concurrency-2</module>
|
<module>core-java-concurrency-2</module>
|
||||||
<module>core-java-concurrency-advanced</module>
|
<module>core-java-concurrency-advanced</module>
|
||||||
|
@ -65,10 +53,7 @@
|
||||||
|
|
||||||
<!--<module>core-java-8-datetime</module>--> <!-- unit test case failure -->
|
<!--<module>core-java-8-datetime</module>--> <!-- unit test case failure -->
|
||||||
<module>core-java-8-datetime-2</module>
|
<module>core-java-8-datetime-2</module>
|
||||||
<!-- <module>core-java-date-operations-1</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<module>core-java-date-operations-2</module>
|
<module>core-java-date-operations-2</module>
|
||||||
<!-- We haven't upgraded to java 9. -->
|
|
||||||
<!-- <module>core-java-datetime-computations</module> <module>core-java-datetime-conversion</module> <module>core-java-datetime-java8</module> <module>core-java-datetime-string</module> -->
|
|
||||||
<module>core-java-8-datetime</module>
|
<module>core-java-8-datetime</module>
|
||||||
|
|
||||||
<module>core-java-exceptions</module>
|
<module>core-java-exceptions</module>
|
||||||
|
@ -85,7 +70,6 @@
|
||||||
|
|
||||||
<module>core-java-jar</module>
|
<module>core-java-jar</module>
|
||||||
<module>core-java-jndi</module>
|
<module>core-java-jndi</module>
|
||||||
<!-- <module>core-java-jpms</module> --> <!-- We haven't upgraded to java 10. Fixing in BAEL-10841 -->
|
|
||||||
<module>core-java-jvm</module>
|
<module>core-java-jvm</module>
|
||||||
<module>core-java-jvm-2</module>
|
<module>core-java-jvm-2</module>
|
||||||
|
|
||||||
|
@ -113,7 +97,6 @@
|
||||||
<module>core-java-nio-2</module>
|
<module>core-java-nio-2</module>
|
||||||
|
|
||||||
<module>core-java-optional</module>
|
<module>core-java-optional</module>
|
||||||
<!--<module>core-java-os</module> --> <!-- We haven't upgraded to java 9. -->
|
|
||||||
|
|
||||||
<module>core-java-perf</module>
|
<module>core-java-perf</module>
|
||||||
|
|
||||||
|
@ -138,9 +121,6 @@
|
||||||
<module>core-java-sun</module>
|
<module>core-java-sun</module>
|
||||||
|
|
||||||
<module>core-java-regex</module>
|
<module>core-java-regex</module>
|
||||||
<!-- <module>core-java-time-measurements</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
|
|
||||||
<!-- <module>multimodulemavenproject</module> --> <!-- We haven't upgraded to java 9. Fixing in BAEL-10841 -->
|
|
||||||
<module>pre-jpms</module>
|
<module>pre-jpms</module>
|
||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
|
|
98
pom.xml
98
pom.xml
|
@ -1340,6 +1340,104 @@
|
||||||
|
|
||||||
</profile>
|
</profile>
|
||||||
|
|
||||||
|
<profile>
|
||||||
|
<id>default-jdk9-and-above</id>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
|
<version>${maven-surefire-plugin.version}</version>
|
||||||
|
<configuration>
|
||||||
|
<forkCount>3</forkCount>
|
||||||
|
<reuseForks>true</reuseForks>
|
||||||
|
<includes>
|
||||||
|
<include>SpringContextTest</include>
|
||||||
|
<include>**/*UnitTest</include>
|
||||||
|
</includes>
|
||||||
|
<excludes>
|
||||||
|
<exclude>**/*IntegrationTest.java</exclude>
|
||||||
|
<exclude>**/*IntTest.java</exclude>
|
||||||
|
<exclude>**/*LongRunningUnitTest.java</exclude>
|
||||||
|
<exclude>**/*ManualTest.java</exclude>
|
||||||
|
<exclude>**/JdbcTest.java</exclude>
|
||||||
|
<exclude>**/*LiveTest.java</exclude>
|
||||||
|
</excludes>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
<modules>
|
||||||
|
<module>core-java-modules/core-java-9</module>
|
||||||
|
<module>core-java-modules/core-java-9-improvements</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-9-jigsaw</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-9-new-features</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-9-streams</module>
|
||||||
|
<module>core-java-modules/core-java-10</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-11</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-12</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-13</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-14</module> --> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-collections-set</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-date-operations-1</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-datetime-conversion</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-datetime-string</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-jpms</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-os</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-time-measurements</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/multimodulemavenproject</module>
|
||||||
|
<!-- <module>maven-java-11</module>--> <!-- Fails -->
|
||||||
|
</modules>
|
||||||
|
</profile>
|
||||||
|
|
||||||
|
<profile>
|
||||||
|
<id>integration-jdk9-and-above</id>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<excludes>
|
||||||
|
<exclude>**/*ManualTest.java</exclude>
|
||||||
|
<exclude>**/*LiveTest.java</exclude>
|
||||||
|
</excludes>
|
||||||
|
<includes>
|
||||||
|
<include>**/*IntegrationTest.java</include>
|
||||||
|
<include>**/*IntTest.java</include>
|
||||||
|
</includes>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
<modules>
|
||||||
|
<module>core-java-modules/core-java-9</module>
|
||||||
|
<module>core-java-modules/core-java-9-improvements</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-9-jigsaw</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-9-new-features</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-9-streams</module>
|
||||||
|
<module>core-java-modules/core-java-10</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-11</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-12</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-13</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-14</module> --> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-collections-set</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-date-operations-1</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-datetime-conversion</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-datetime-string</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/core-java-jpms</module>
|
||||||
|
<!-- <module>core-java-modules/core-java-os</module>--> <!-- Fails -->
|
||||||
|
<!-- <module>core-java-modules/core-java-time-measurements</module>--> <!-- Fails -->
|
||||||
|
<module>core-java-modules/multimodulemavenproject</module>
|
||||||
|
<!-- <module>maven-java-11</module>--> <!-- Fails -->
|
||||||
|
</modules>
|
||||||
|
</profile>
|
||||||
</profiles>
|
</profiles>
|
||||||
|
|
||||||
<reporting>
|
<reporting>
|
||||||
|
|
Loading…
Reference in New Issue