-
Bug
-
Resolution: Fixed
-
Normal
-
3.5.0 RC
-
None
SBook book = SBooks.createBook("book1");
book.getBookSeries().setAutoFormulaCacheClean(true);
SSheet sheet1 = book.createSheet("SheetX");
SName name = book.createName("FOO");
name.setRefersToFormula("SheetX!A1:B2");
// test insert/delete cells
sheet1.getCell("A1").setValue(1);
sheet1.getCell("B1").setValue(2);
sheet1.getCell("A2").setValue(3);
sheet1.getCell("B2").setValue(4);
Assert.assertEquals("SheetX!A1:B2", name.getRefersToFormula());
Assert.assertEquals(10D, sheet1.getCell("D2").getValue());
// insert B1:B1
sheet1.insertCell(0, 1, 0, 1, true);
Assert.assertEquals("SheetX!A1:B2", name.getRefersToFormula());
Assert.assertEquals(8D, sheet1.getCell("D2").getValue());