Skip to content

Commit

Permalink
Fix unit test for Java 16.
Browse files Browse the repository at this point in the history
  • Loading branch information
joehni committed Mar 20, 2021
1 parent 4c3d4f4 commit 7ceb42b
Showing 1 changed file with 31 additions and 2 deletions.
33 changes: 31 additions & 2 deletions xstream/src/test/com/thoughtworks/acceptance/XmlFriendlyTest.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* Copyright (C) 2006 Joe Walnes.
* Copyright (C) 2006, 2007, 2011, 2017, 2018, 2019, 2020 XStream Committers.
* Copyright (C) 2006, 2007, 2011, 2017, 2018, 2019, 2020, 2021 XStream Committers.
* All rights reserved.
*
* The software in this package is published under the terms of the BSD
Expand Down Expand Up @@ -249,7 +249,7 @@ public void testDecimalFormatSymbols() {
+ " </default>\n"
+ " </java.text.DecimalFormatSymbols>\n"
+ "</java.text.DecimalFormatSymbols>";
} else {
} else if (!JVM.isVersion(16)) {
xml = ""
+ "<java.text.DecimalFormatSymbols serialization=\"custom\">\n"
+ " <java.text.DecimalFormatSymbols>\n"
Expand Down Expand Up @@ -279,6 +279,35 @@ public void testDecimalFormatSymbols() {
+ " </default>\n"
+ " </java.text.DecimalFormatSymbols>\n"
+ "</java.text.DecimalFormatSymbols>";
} else {
xml = ""
+ "<java.text.DecimalFormatSymbols serialization=\"custom\">\n"
+ " <java.text.DecimalFormatSymbols>\n"
+ " <default>\n"
+ " <decimalSeparator>,</decimalSeparator>\n"
+ " <digit>#</digit>\n"
+ " <exponential>E</exponential>\n"
+ " <groupingSeparator>.</groupingSeparator>\n"
+ " <minusSign>-</minusSign>\n"
+ " <monetaryGroupingSeparator>.</monetaryGroupingSeparator>\n"
+ " <monetarySeparator>,</monetarySeparator>\n"
+ " <patternSeparator>;</patternSeparator>\n"
+ " <perMill>\u2030</perMill>\n"
+ " <percent>%</percent>\n"
+ " <serialVersionOnStream>5</serialVersionOnStream>\n"
+ " <zeroDigit>0</zeroDigit>\n"
+ " <NaN>NaN</NaN>\n"
+ " <currencySymbol>\u20ac</currencySymbol>\n"
+ " <exponentialSeparator>E</exponentialSeparator>\n"
+ " <infinity>\u221e</infinity>\n"
+ " <intlCurrencySymbol>EUR</intlCurrencySymbol>\n"
+ " <locale>de_DE</locale>\n"
+ " <minusSignText>-</minusSignText>\n"
+ " <perMillText>\u2030</perMillText>\n"
+ " <percentText>%</percentText>\n"
+ " </default>\n"
+ " </java.text.DecimalFormatSymbols>\n"
+ "</java.text.DecimalFormatSymbols>";
}
final DecimalFormatSymbols format = new DecimalFormatSymbols(Locale.GERMANY);
format.setNaN("NaN");
Expand Down

0 comments on commit 7ceb42b

Please sign in to comment.