You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Unico Hommes (JIRA)" <ji...@apache.org> on 2014/12/03 16:41:13 UTC
[jira] [Created] (JCR-3834) DecimalField calculates wrong string
from BigDecimal with scale of Integer.MIN_VALUE
Unico Hommes created JCR-3834:
---------------------------------
Summary: DecimalField calculates wrong string from BigDecimal with scale of Integer.MIN_VALUE
Key: JCR-3834
URL: https://issues.apache.org/jira/browse/JCR-3834
Project: Jackrabbit Content Repository
Issue Type: Bug
Reporter: Unico Hommes
The following test fails
public void testMinimumScale() {
final BigDecimal d1 = new BigDecimal(BigInteger.ONE, Integer.MIN_VALUE);
final BigDecimal d2 = new BigDecimal(BigInteger.ONE, Integer.MIN_VALUE+1);
final String s1 = DecimalField.decimalToString(d1);
final String s2 = DecimalField.decimalToString(d2);
assertEquals(Math.signum(d1.compareTo(d2)), Math.signum(s1.compareTo(s2)));
}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)