update to xbib-net 2.0.3, jackson 2.9.10.1, woodstox 6.0.2, junit 5.5.2, hamcrest 2.1, mockito 3.1.0

This commit is contained in:
Jörg Prante 2019-11-06 21:40:15 +01:00
parent b27158d62e
commit 1f80fa1740
6 changed files with 42 additions and 24 deletions

4
.travis.yml Normal file
View file

@ -0,0 +1,4 @@
language: java
jdk:
- openjdk11

View file

@ -1,8 +1,8 @@
plugins { plugins {
id "org.sonarqube" version "2.6.1" id "org.sonarqube" version "2.8"
id "io.codearte.nexus-staging" version "0.11.0" id "io.codearte.nexus-staging" version "0.21.1"
id "com.github.spotbugs" version "2.0.0" id "com.github.spotbugs" version "2.0.1"
id "org.xbib.gradle.plugin.asciidoctor" version "1.5.6.0.1" id "org.xbib.gradle.plugin.asciidoctor" version "1.5.6.0.1"
} }
@ -24,7 +24,11 @@ subprojects {
} }
dependencies { dependencies {
testCompile "junit:junit:${project.property('junit.version')}" testCompile "org.junit.jupiter:junit-jupiter-api:${project.property('junit.version')}"
testCompile "org.junit.jupiter:junit-jupiter-params:${project.property('junit.version')}"
testCompile "org.junit.jupiter:junit-jupiter-engine:${project.property('junit.version')}"
testCompile "org.junit.vintage:junit-vintage-engine:${project.property('junit.version')}"
testCompile "junit:junit:${project.property('junit4.version')}"
asciidoclet "org.asciidoctor:asciidoclet:${project.property('asciidoclet.version')}" asciidoclet "org.asciidoctor:asciidoclet:${project.property('asciidoclet.version')}"
} }
@ -44,9 +48,19 @@ subprojects {
} }
test { test {
useJUnitPlatform()
failFast = false
testLogging { testLogging {
showStandardStreams = false events 'STARTED', 'PASSED', 'FAILED', 'SKIPPED'
exceptionFormat = 'full' }
afterSuite { desc, result ->
if (!desc.parent) {
println "\nTest result: ${result.resultType}"
println "Test summary: ${result.testCount} tests, " +
"${result.successfulTestCount} succeeded, " +
"${result.failedTestCount} failed, " +
"${result.skippedTestCount} skipped"
}
} }
} }
@ -112,7 +126,6 @@ subprojects {
} }
} }
ext { ext {
projectDescription = 'Content processing library for Java' projectDescription = 'Content processing library for Java'
scmUrl = 'https://github.com/xbib/content' scmUrl = 'https://github.com/xbib/content'
@ -175,5 +188,4 @@ subprojects {
nexusStaging { nexusStaging {
packageGroup = "org.xbib" packageGroup = "org.xbib"
} }
} }

View file

@ -879,14 +879,18 @@ public final class XContentBuilder implements ToXContent, Flushable, Closeable {
} else if (value instanceof Iterable) { } else if (value instanceof Iterable) {
generator.writeStartArray(); generator.writeStartArray();
for (Object v : (Iterable) value) { for (Object v : (Iterable) value) {
if (v != value) {
writeValue(v); writeValue(v);
} }
}
generator.writeEndArray(); generator.writeEndArray();
} else if (value instanceof Object[]) { } else if (value instanceof Object[]) {
generator.writeStartArray(); generator.writeStartArray();
for (Object v : (Object[]) value) { for (Object v : (Object[]) value) {
if (v != value) {
writeValue(v); writeValue(v);
} }
}
generator.writeEndArray(); generator.writeEndArray();
} else if (type == byte[].class) { } else if (type == byte[].class) {
generator.writeBinary((byte[]) value); generator.writeBinary((byte[]) value);

View file

@ -1,10 +1,10 @@
dependencies { dependencies {
compile "com.fasterxml.jackson.core:jackson-databind:${project.property('jackson.version')}" compile "com.fasterxml.jackson.core:jackson-databind:${project.property('jackson.version')}"
testCompile("junit:junit:${project.property('junit.version')}") { testCompile("junit:junit:${project.property('junit4.version')}") {
exclude group: 'org.hamcrest' exclude group: 'org.hamcrest'
} }
testCompile("org.mockito:mockito-core:${project.property('mockito.version')}") { testCompile("org.mockito:mockito-core:${project.property('mockito.version')}") {
exclude group: 'org.hamcrest' exclude group: 'org.hamcrest'
} }
testCompile "org.hamcrest:hamcrest-all:${project.property('hamcrest.version')}" testCompile "org.hamcrest:hamcrest-library:${project.property('hamcrest.version')}"
} }

View file

@ -1,4 +1,3 @@
dependencies { dependencies {
compile "org.xbib:net-url:${project.property('xbib-net.version')}" compile "org.xbib:net-url:${project.property('xbib-net.version')}"
testCompile "com.fasterxml.jackson.core:jackson-databind:${project.property('jackson.version')}" testCompile "com.fasterxml.jackson.core:jackson-databind:${project.property('jackson.version')}"

View file

@ -1,18 +1,17 @@
group = org.xbib group = org.xbib
name = content name = content
version = 2.0.2 version = 2.0.4
xbib-net.version = 2.0.1 xbib-net.version = 2.0.3
jackson.version = 2.9.9 jackson.version = 2.9.10
jackson-databind.version = 2.9.9.2 jackson-databind.version = 2.9.10.1
woodstox.version = 6.0.1 woodstox.version = 6.0.2
# test # test
junit.version = 4.12 junit.version = 5.5.2
hamcrest.version = 1.3 junit4.version = 4.12
mockito.version = 2.25.1 hamcrest.version = 2.1
mockito.version = 3.1.0
# doc # doc
asciidoclet.version = 1.5.4 asciidoclet.version = 1.5.6
org.gradle.warning.mode = all