diff options
author | Dominik Stadler <centic@apache.org> | 2020-03-29 08:16:17 +0000 |
---|---|---|
committer | Dominik Stadler <centic@apache.org> | 2020-03-29 08:16:17 +0000 |
commit | cc1b6557ee514aa2f9997b104c42a09aae3400e3 (patch) | |
tree | 644cde8d797a4e1a2bfde372bcba97d78a28d1ae /src/testcases/org/apache | |
parent | f58aa530da8ec1871e445c706d7e915be68998a6 (diff) | |
download | poi-cc1b6557ee514aa2f9997b104c42a09aae3400e3.tar.gz poi-cc1b6557ee514aa2f9997b104c42a09aae3400e3.zip |
Bug 63845: Adjust handling of formula-cells to fix regression introduced in 4.1.0
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1875837 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/testcases/org/apache')
-rw-r--r-- | src/testcases/org/apache/poi/ss/usermodel/BaseTestCell.java | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/testcases/org/apache/poi/ss/usermodel/BaseTestCell.java b/src/testcases/org/apache/poi/ss/usermodel/BaseTestCell.java index e6913c19a0..2ab0f48b5e 100644 --- a/src/testcases/org/apache/poi/ss/usermodel/BaseTestCell.java +++ b/src/testcases/org/apache/poi/ss/usermodel/BaseTestCell.java @@ -1352,7 +1352,8 @@ public abstract class BaseTestCell { cell.setCellFormula("\"foo\""); assertEquals(CellType.FORMULA, cell.getCellType()); assertEquals(CellType.BOOLEAN, cell.getCachedFormulaResultType()); - assertTrue(cell.getBooleanCellValue()); + assertTrue("Expected a boolean cell-value, but had 'false'", + cell.getBooleanCellValue()); } } @@ -1369,7 +1370,8 @@ public abstract class BaseTestCell { cell.setCellFormula("\"bar\""); assertEquals(CellType.FORMULA, cell.getCellType()); assertEquals(CellType.BOOLEAN, cell.getCachedFormulaResultType()); - assertTrue(cell.getBooleanCellValue()); + assertTrue("Expected a boolean cell-value, but had 'false'", + cell.getBooleanCellValue()); } } @@ -1387,8 +1389,10 @@ public abstract class BaseTestCell { cell.getSheet().setArrayFormula("\"bar\"", CellRangeAddress.valueOf("A1")); assertEquals(CellType.FORMULA, cell.getCellType()); - assertEquals(CellType.BOOLEAN, cell.getCachedFormulaResultType()); - assertTrue(cell.getBooleanCellValue()); + assertEquals("Expected a boolean cell-value, but had " + cell.getCachedFormulaResultType(), + CellType.BOOLEAN, cell.getCachedFormulaResultType()); + assertTrue("Expected a boolean cell-value, but had 'false'", + cell.getBooleanCellValue()); } } |