@@ -94,7 +94,6 @@ allprojects {
|
||||
sqlfireclientVersion = '1.0.3'
|
||||
sqliteVersion = '3.25.2'
|
||||
woodstoxVersion = '5.0.3'
|
||||
xercesVersion = '2.11.0' //?
|
||||
xmlunitVersion = '2.6.2'
|
||||
xstreamVersion = '1.4.10'
|
||||
jrubyVersion = '1.7.26'
|
||||
@@ -465,7 +464,6 @@ project('spring-batch-infrastructure-tests') {
|
||||
}
|
||||
testCompile "org.apache.logging.log4j:log4j-api:$log4jVersion"
|
||||
testCompile "org.apache.logging.log4j:log4j-core:$log4jVersion"
|
||||
testCompile "xerces:xercesImpl:$xercesVersion"
|
||||
testCompile "com.thoughtworks.xstream:xstream:$xstreamVersion"
|
||||
testCompile("com.fasterxml.woodstox:woodstox-core:$woodstoxVersion") {
|
||||
exclude group: 'stax', module: 'stax-api'
|
||||
|
||||
@@ -23,8 +23,8 @@ dn: cn=Gern Jensen,ou=Product Testing,dc=airius,dc=com
|
||||
telephonenumber: +1 408 555 1212
|
||||
uid: gernj
|
||||
description:: V2hhdCBhIGNhcmVmdWwgcmVhZGVyIHlvdSBhcmUhICBUaGlzIHZhbHVlIGlzIGJhc2UtNjQtZW5j
|
||||
b2RlZCBiZWNhdXNlIGl0IGhhcyBhIGNvbnRyb2wgY2hhcmFjdGVyIGluIGl0IChhIENSKS4NICBC
|
||||
eSB0aGUgd2F5LCB5b3Ugc2hvdWxkIHJlYWxseSBnZXQgb3V0IG1vcmUu
|
||||
b2RlZCBiZWNhdXNlIGl0IGhhcyBhIGNvbnRyb2wgY2hhcmFjdGVyIGluIGl0IChhIENSKS4NICBC
|
||||
eSB0aGUgd2F5LCB5b3Ugc2hvdWxkIHJlYWxseSBnZXQgb3V0IG1vcmUu
|
||||
objectclass: top
|
||||
objectclass: person
|
||||
objectclass: organizationalPerson
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2018 the original author or authors.
|
||||
* Copyright 2018-2019 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -70,6 +70,20 @@ public abstract class JsonItemReaderFunctionalTests {
|
||||
Assert.assertEquals(new BigDecimal("1.4"), trade.getPrice());
|
||||
Assert.assertEquals(2, trade.getQuantity());
|
||||
|
||||
trade = itemReader.read();
|
||||
Assert.assertNotNull(trade);
|
||||
Assert.assertEquals("789", trade.getIsin());
|
||||
Assert.assertEquals("foobar", trade.getCustomer());
|
||||
Assert.assertEquals(new BigDecimal("1.6"), trade.getPrice());
|
||||
Assert.assertEquals(3, trade.getQuantity());
|
||||
|
||||
trade = itemReader.read();
|
||||
Assert.assertNotNull(trade);
|
||||
Assert.assertEquals("100", trade.getIsin());
|
||||
Assert.assertEquals("barfoo", trade.getCustomer());
|
||||
Assert.assertEquals(new BigDecimal("1.8"), trade.getPrice());
|
||||
Assert.assertEquals(4, trade.getQuantity());
|
||||
|
||||
trade = itemReader.read();
|
||||
Assert.assertNull(trade);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2017 the original author or authors.
|
||||
* Copyright 2010-2019 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -26,6 +26,8 @@ import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.xmlunit.builder.Input;
|
||||
import org.xmlunit.diff.DefaultNodeMatcher;
|
||||
import org.xmlunit.diff.ElementSelectors;
|
||||
import org.xmlunit.matchers.CompareMatcher;
|
||||
|
||||
import org.springframework.batch.item.ExecutionContext;
|
||||
@@ -97,7 +99,8 @@ public abstract class AbstractStaxEventWriterItemWriterTests {
|
||||
|
||||
assertThat(
|
||||
Input.from(expected.getFile()),
|
||||
CompareMatcher.isSimilarTo(Input.from(resource.getFile())));
|
||||
CompareMatcher.isSimilarTo(Input.from(resource.getFile()))
|
||||
.withNodeMatcher(new DefaultNodeMatcher(ElementSelectors.byNameAndText)));
|
||||
}
|
||||
|
||||
@Before
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2010-2014 the original author or authors.
|
||||
* Copyright 2010-2019 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -101,7 +101,7 @@ public class Jaxb2NamespaceMarshallingTests {
|
||||
|
||||
assertThat(
|
||||
Input.from(expected.getFile()),
|
||||
CompareMatcher.isSimilarTo(Input.from(resource.getFile())));
|
||||
CompareMatcher.isSimilarTo(Input.from(resource.getFile())).normalizeWhitespace());
|
||||
}
|
||||
|
||||
@Before
|
||||
|
||||
Reference in New Issue
Block a user