FileDocCategorySizeDatePackage
TestRangePtg.javaAPI DocApache Poi 3.0.11678Mon Jan 01 12:39:46 GMT 2007org.apache.poi.hssf.record.formula

TestRangePtg

public class TestRangePtg extends AbstractPtgTestCase
Tests for {@link RangePtg}.
author
Daniel Noll (daniel at nuix dot com dot au)

Fields Summary
Constructors Summary
Methods Summary
public voidtestReading()
Tests reading a file containing this ptg.

        HSSFWorkbook workbook = loadWorkbook("RangePtg.xls");
        HSSFCell cell = workbook.getSheetAt(0).getRow(3).getCell((short) 1);
        assertEquals("Wrong cell value", 10.0, cell.getNumericCellValue(), 0.0);
        assertEquals("Wrong cell formula", "SUM(pineapple:B2)", cell.getCellFormula());