diff options
author | PJ Fanning <fanningpj@apache.org> | 2020-06-11 11:04:23 +0000 |
---|---|---|
committer | PJ Fanning <fanningpj@apache.org> | 2020-06-11 11:04:23 +0000 |
commit | b6ea06d220c334f1232ae9cfa6675e8bbde35f06 (patch) | |
tree | 57cdaddd8d5bbfa54c60e6cb8a1aa15b9b61da8b /src | |
parent | 30f909e05bd28ebc4270697213f43350e09cc2c6 (diff) | |
download | poi-b6ea06d220c334f1232ae9cfa6675e8bbde35f06.tar.gz poi-b6ea06d220c334f1232ae9cfa6675e8bbde35f06.zip |
try to fix broken test
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1878750 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r-- | src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java | 5 | ||||
-rw-r--r-- | src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java b/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java index 008f8728d9..954803bb86 100644 --- a/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java +++ b/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFSheet.java @@ -3545,8 +3545,9 @@ public class XSSFSheet extends POIXMLDocumentPart implements Sheet { // see more details in https://issues.apache.org/bugzilla/show_bug.cgi?id=51710 if(cellRef.getCol() > sfRef.getFirstColumn() || cellRef.getRow() > sfRef.getFirstRow()){ String effectiveRef = new CellRangeAddress( - Math.max(cellRef.getRow(), sfRef.getFirstRow()), sfRef.getLastRow(), - Math.max(cellRef.getCol(), sfRef.getFirstColumn()), sfRef.getLastColumn()).formatAsString(); + Math.max(cellRef.getRow(), sfRef.getFirstRow()), Math.max(cellRef.getRow(), sfRef.getLastRow()), + Math.max(cellRef.getCol(), sfRef.getFirstColumn()), Math.max(cellRef.getCol(), sfRef.getLastColumn())) + .formatAsString(); sf.setRef(effectiveRef); } diff --git a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java index dd2c348a58..f8e76cfc17 100644 --- a/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java +++ b/src/ooxml/testcases/org/apache/poi/xssf/usermodel/TestXSSFSheetShiftRows.java @@ -23,7 +23,6 @@ import org.apache.poi.ss.util.CellUtil; import org.apache.poi.util.IOUtils; import org.apache.poi.xssf.XSSFITestDataProvider; import org.apache.poi.xssf.XSSFTestDataSamples; -import org.junit.Ignore; import org.junit.Test; import java.io.IOException; @@ -397,7 +396,6 @@ public final class TestXSSFSheetShiftRows extends BaseTestSheetShiftRows { // bug 59983: Wrong update of shared formulas after shiftRow @Test - @Ignore public void testSharedFormulas() throws Exception { XSSFWorkbook wb = XSSFTestDataSamples.openSampleWorkbook("TestShiftRowSharedFormula.xlsx"); XSSFSheet sheet = wb.getSheetAt(0); |