From f7e0bdea37393a954c4eb9f2231091da03779ee0 Mon Sep 17 00:00:00 2001 From: Dominik Stadler Date: Thu, 3 Sep 2015 20:46:14 +0000 Subject: [PATCH] Add unit test which verifies that bug 53105 is actually fixed now git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1701133 13f79535-47bb-0310-9956-ffa450edef68 --- .../poi/xssf/usermodel/TestXSSFBugs.java | 17 +++++++++++++++++ test-data/spreadsheet/53105.xlsx | Bin 0 -> 50118 bytes 2 files changed, 17 insertions(+) create mode 100644 test-data/spreadsheet/53105.xlsx diff --git a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java index 5fccecc68..41e0580b7 100644 --- a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java +++ b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFBugs.java @@ -2616,4 +2616,21 @@ public final class TestXSSFBugs extends BaseTestBugzillaIssues { wb.close(); } + + @Test + public void test53105() throws IOException { + Workbook wb = XSSFTestDataSamples.openSampleWorkbook("53105.xlsx"); + assertNotNull(wb); + + + // Act + // evaluate SUM('Skye Lookup Input'!A4:XFD4), cells in range each contain "1" + FormulaEvaluator evaluator = wb.getCreationHelper().createFormulaEvaluator(); + double numericValue = evaluator.evaluate(wb.getSheetAt(0).getRow(1).getCell(0)).getNumberValue(); + + // Assert + assertEquals(16384.0, numericValue, 0.0); + + wb.close(); + } } diff --git a/test-data/spreadsheet/53105.xlsx b/test-data/spreadsheet/53105.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..80ec056e4693f70d59c96a382eb764d07734095d GIT binary patch literal 50118 zcmeHw2{@JC-u9AVQHn|_V?`w?lA=r%%2>p%%$Y)&YR{v`khw@oB2uJ*D56X|ArVTZ zBB>08%_cq>kKEt6cdlYbjf6zN>CvN}>8DZ`pJS9KQCEvQFQUC1(Dv)|;*%VGeLSaOc%|Y! zwJlW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