aboutsummaryrefslogtreecommitdiffstats
path: root/src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java
diff options
context:
space:
mode:
authorNick Burch <nick@apache.org>2013-06-26 20:40:26 +0000
committerNick Burch <nick@apache.org>2013-06-26 20:40:26 +0000
commitea1bb016a944cd8d5673e73d36bd9dc7d097bbba (patch)
treee6629ec3f7024fbf9748bc68015a17876664c95e /src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java
parent2d0241181a52b216852bb5c248a46ef2ce2577a1 (diff)
downloadpoi-ea1bb016a944cd8d5673e73d36bd9dc7d097bbba.tar.gz
poi-ea1bb016a944cd8d5673e73d36bd9dc7d097bbba.zip
Add a test to show that bug #53150 has been fixed by the recent fraction work
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1497084 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java')
-rw-r--r--src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java b/src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java
index 6dcd6ebeba..2816a488f4 100644
--- a/src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java
+++ b/src/testcases/org/apache/poi/ss/usermodel/TestDataFormatter.java
@@ -248,6 +248,9 @@ public class TestDataFormatter extends TestCase {
//Bug54868 patch has a hit on the first string before the ";"
assertEquals("-123 1/3", dfUS.formatRawCellContents(-123.321, -1, "0 ?/?;0"));
+ //Bug53150 formatting a whole number with fractions should just give the number
+ assertEquals("1", dfUS.formatRawCellContents(1.0, -1, "# #/#"));
+ assertEquals("11", dfUS.formatRawCellContents(11.0, -1, "# #/#"));
}
/**