BAEL-17950 Fix the integrations tests in xml (#7882)
-Fixed integration test issue and renamed the class back to *UnitTest as its not an integration test at all
This commit is contained in:
parent
cd032c9d73
commit
5373bc1719
81
xml/pom.xml
81
xml/pom.xml
@ -137,25 +137,68 @@
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<finalName>xml</finalName>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src/main/resources</directory>
|
||||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>${maven-compiler-plugin.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<version>${maven-surefire-plugin.version}</version>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
<build>
|
||||
<finalName>xml</finalName>
|
||||
<resources>
|
||||
<resource>
|
||||
<directory>src/main/resources</directory>
|
||||
<filtering>true</filtering>
|
||||
</resource>
|
||||
</resources>
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.jibx</groupId>
|
||||
<artifactId>maven-jibx-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.jibx</groupId>
|
||||
<artifactId>maven-jibx-plugin</artifactId>
|
||||
<version>${maven-jibx-plugin.version}</version>
|
||||
<configuration>
|
||||
<directory>src/main/resources</directory>
|
||||
<includes>
|
||||
<includes>*-binding.xml</includes>
|
||||
</includes>
|
||||
<excludes>
|
||||
<exclude>template-binding.xml</exclude>
|
||||
</excludes>
|
||||
<schemaBindingDirectory>src/main/resources</schemaBindingDirectory>
|
||||
<includeSchemaBindings>
|
||||
<includeSchemaBindings>*-binding.xml</includeSchemaBindings>
|
||||
</includeSchemaBindings>
|
||||
<verbose>true</verbose>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>process-classes</id>
|
||||
<phase>process-classes</phase>
|
||||
<goals>
|
||||
<goal>bind</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>process-test-classes</id>
|
||||
<phase>process-test-classes</phase>
|
||||
<goals>
|
||||
<goal>test-bind</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>${maven-compiler-plugin.version}</version>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-surefire-plugin</artifactId>
|
||||
<version>${maven-surefire-plugin.version}</version>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
|
@ -11,7 +11,7 @@ import java.io.InputStream;
|
||||
|
||||
import static junit.framework.Assert.assertEquals;
|
||||
|
||||
public class CustomerIntegrationTest {
|
||||
public class CustomerUnitTest {
|
||||
|
||||
@Test
|
||||
public void whenUnmarshalXML_ThenFieldsAreMapped() throws JiBXException, FileNotFoundException {
|
||||
@ -21,7 +21,7 @@ public class CustomerIntegrationTest {
|
||||
InputStream inputStream = classLoader.getResourceAsStream("Customer1.xml");
|
||||
Customer customer = (Customer) uctx.unmarshalDocument(inputStream, null);
|
||||
|
||||
assertEquals("Stefan Jaegar", customer.getPerson().getName());
|
||||
assertEquals("Stefan Jaeger", customer.getPerson().getName());
|
||||
assertEquals("Davos Dorf", customer.getCity());
|
||||
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user