Save This Page
Home » cocoon-2.1.11-src » org.apache.cocoon.poi » hssf » usermodel » [javadoc | source]
org.apache.cocoon.poi.hssf.usermodel
public class: TestWorkbook [javadoc | source]
java.lang.Object
   TestCase
      org.apache.cocoon.poi.hssf.usermodel.TestWorkbook
Class to test Workbook functionality
Constructor:
 public TestWorkbook(String name) 
    Constructor TestWorkbook
    Parameters:
    name -
Method from org.apache.cocoon.poi.hssf.usermodel.TestWorkbook Summary:
main,   testModifyEmployee,   testModifySimple,   testModifySimpleWithSkip,   testModifySimpleWithStyling,   testReadEmployeeSimple,   testReadSheetWithRK,   testReadSimple,   testWriteModifySheetSimple,   testWriteSheetSimple
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.cocoon.poi.hssf.usermodel.TestWorkbook Detail:
 public static  void main(String[] ignored_args) 
 public  void testModifyEmployee() throws IOException 
    TEST NAME: Test Modify Employee Sheet

    OBJECTIVE: Test that HSSF can read a simple spreadsheet with string values and replace them with other string values despite any styling. In this release of HSSF styling will probably be lost and is NOT tested.

    SUCCESS: HSSF reads a sheet. HSSF replaces the cell values with other cell values. HSSF writes the sheet out to another file. HSSF reads the result and ensures the value has been properly replaced.

    FAILURE: HSSF does not read a sheet or excepts. HSSF does not write the sheet or excepts. HSSF does not re-read the sheet or excepts. Upon re-reading the sheet the value is incorrect or has not been replaced.

 public  void testModifySimple() throws IOException 
    TEST NAME: Test Modify Sheet Simple

    OBJECTIVE: Test that HSSF can read a simple spreadsheet with a string value and replace it with another string value.

    SUCCESS: HSSF reads a sheet. HSSF replaces the cell value with another cell value. HSSF writes the sheet out to another file. HSSF reads the result and ensures the value has been properly replaced.

    FAILURE: HSSF does not read a sheet or excepts. HSSF does not write the sheet or excepts. HSSF does not re-read the sheet or excepts. Upon re-reading the sheet the value is incorrect or has not been replaced.

 public  void testModifySimpleWithSkip() throws IOException 
    TEST NAME: Test Modify Sheet Simple With Skipped cells

    OBJECTIVE: Test that HSSF can read a simple spreadsheet with string values and replace them with other string values while not replacing other cells.

    SUCCESS: HSSF reads a sheet. HSSF replaces the cell value with another cell value. HSSF writes the sheet out to another file. HSSF reads the result and ensures the value has been properly replaced and unreplaced values are still unreplaced.

    FAILURE: HSSF does not read a sheet or excepts. HSSF does not write the sheet or excepts. HSSF does not re-read the sheet or excepts. Upon re-reading the sheet the value is incorrect or has not been replaced or the incorrect cell has its value replaced or is incorrect.

 public  void testModifySimpleWithStyling() throws IOException 
    TEST NAME: Test Modify Sheet With Styling

    OBJECTIVE: Test that HSSF can read a simple spreadsheet with string values and replace them with other string values despite any styling. In this release of HSSF styling will probably be lost and is NOT tested.

    SUCCESS: HSSF reads a sheet. HSSF replaces the cell values with other cell values. HSSF writes the sheet out to another file. HSSF reads the result and ensures the value has been properly replaced.

    FAILURE: HSSF does not read a sheet or excepts. HSSF does not write the sheet or excepts. HSSF does not re-read the sheet or excepts. Upon re-reading the sheet the value is incorrect or has not been replaced.

 public  void testReadEmployeeSimple() throws IOException 
    TEST NAME: Test Read Employee Simple

    OBJECTIVE: Test that HSSF can read a simple spreadsheet (Employee.xls).

    SUCCESS: HSSF reads the sheet. Matches values in their particular positions.

    FAILURE: HSSF does not read a sheet or excepts. HSSF cannot identify values in the sheet in their known positions.

 public  void testReadSheetWithRK() throws IOException 
    TEST NAME: Test Read Sheet with an RK number

    OBJECTIVE: Test that HSSF can read a simple spreadsheet with and RKRecord and correctly identify the cell as numeric and convert it to a NumberRecord.

    SUCCESS: HSSF reads a sheet. HSSF returns that the cell is a numeric type cell.

    FAILURE: HSSF does not read a sheet or excepts. HSSF incorrectly indentifies the cell

 public  void testReadSimple() throws IOException 
    TEST NAME: Test Read Simple

    OBJECTIVE: Test that HSSF can read a simple spreadsheet (Simple.xls).

    SUCCESS: HSSF reads the sheet. Matches values in their particular positions.

    FAILURE: HSSF does not read a sheet or excepts. HSSF cannot identify values in the sheet in their known positions.

 public  void testWriteModifySheetSimple() throws IOException 
    TEST NAME: Test Write/Modify Sheet Simple

    OBJECTIVE: Test that HSSF can create a simple spreadsheet with numeric and string values, remove some rows, yet still have a valid file/data.

    SUCCESS: HSSF creates a sheet. Filesize matches a known good. HSSFSheet objects Last row, first row is tested against the correct values (74,25).

    FAILURE: HSSF does not create a sheet or excepts. Filesize does not match the known good. HSSFSheet last row or first row is incorrect.

 public  void testWriteSheetSimple() throws IOException 
    TEST NAME: Test Write Sheet Simple

    OBJECTIVE: Test that HSSF can create a simple spreadsheet with numeric and string values.

    SUCCESS: HSSF creates a sheet. Filesize matches a known good. HSSFSheet objects Last row, first row is tested against the correct values (99,0).

    FAILURE: HSSF does not create a sheet or excepts. Filesize does not match the known good. HSSFSheet last row or first row is incorrect.